Jump to content

Tanjiro

Members
  • Posts

    82
  • Joined

  • Last visited

  • Days Won

    3

Posts posted by Tanjiro

  1. On 4/5/2023 at 8:35 PM, Westcircle said:

    Maybe it just happened to me. I'm not blaming them for anything, their support was very good. I am just saying, if somebody encounters such an issue, at least they will know where to start digging :classic_smile:

    P.S. Thanks for the sitemap tip, just updated mine according the tutorial 

    You're correct, I'm digging this issue right now, I was trying to find out why the hell Google Search Console keep saying "Couldn't fetch" for hours, I was looking to robots.txt file and I know why, I keep finding on kvs forum and found this topic, thank you for your topic, I also find @3dz 's comment very useful, I'll definitely look into it, thank you both

  2. On 6/6/2022 at 8:52 PM, Tech Support said:

    It can be translated in Administration -> Translations section.

    Hi again, sorry bother you this but I don't understand how it works

    image.png.d606a5304c429ee8d212bbd33de5b8f4.png

    Let's say my default language is Polish, and I have this category, and when other people switch to English language, how can I translate "surowy film" to English word ?

    I tried to fill "Title for Polish" box and Description for Polish" box but it didn't translate at all, when I switch to English it still shows "surowy film"

  3. On 7/29/2023 at 5:17 PM, Akash Bhati said:

    Hello,
    Firstly, the conditions and rules you mentioned are in Apache's mod_rewrite syntax, but Nginx uses a different configuration style. Here is the corresponding setup in Nginx:
     

    Let me explain what this does:

    1. location /admin: This block applies to any URL path that starts with /admin.
    2. allow 88.85.69.0/24; deny all;: These two lines control access to the /admin directory. Only IP addresses in the range 88.85.69.0 to 88.85.69.255 are allowed. All other IP addresses are denied.
    3. error_page 403 =404 /404.html;: This changes the error page for forbidden requests (403 errors) to your 404 error page. Replace /404.html with the path to your actual 404 error page.
    4. try_files $uri $uri/ =404;: This tries to serve the request as is, or as a directory, and if neither of those exist, it returns a 404 error.
    5. location ~ \.php$ { deny all; }: This nested location block matches any PHP file in the /admin directory and denies access to it.

    However, please be careful as this block will need to be adjusted to fit in with your existing PHP execution configuration, especially if you're using PHP-FPM or similar.

    In Nginx, the client's IP is taken from the connection itself and not from an HTTP header like HTTP:X-REAL-IP as in your Apache configuration. If you're behind a proxy and want to allow/deny based on the original client IP, you'll need to use the ngx_http_realip_module and define trusted sources to get the real IP.

     

    Looks like no one care but I do care, thank you for the tutorial

    • Like 1
  4. 9 hours ago, Tech Support said:

    Please go to Website UI -> Theme settings and locate active link to modify Profile options at the bottom. It will bring you to modify member_profile_edit block, in template you need to find the row for editing display name and add hidden class to it:

    <div class="row hidden">
    	<label for="edit_profile_display_name" class="field-label required">{{$lang.edit_profile.field_display_name}}</label>
    	<input type="text" name="display_name" id="edit_profile_display_name" class="textfield" value="{{$smarty.post.display_name}}" {{if $lang.memberzone.truncate_username_to>0}}maxlength="{{$lang.memberzone.truncate_username_to}}"{{/if}} placeholder="{{$lang.edit_profile.field_display_name_hint}}"/>
    	<div class="field-error down"></div>
    </div>

     

    If someone view sources code they can still uncheck hidden (which is display:none) and the Display name box will appears again, can I comment {**} (or remove) this div?

  5. 16 hours ago, Tech Support said:

    This is a know KVS 6.1.2 bug :( Some feedbacks will fail to be created. We may need to provide a patch for this, but what we noticed in some projects, usually spam comes into errors.

    Lots of work to do for KVS team🙏

    Btw, because I want to watermark text to video like "Uploaded by (user)" so I think the display name must be restricted at certain level, like number of character allowed, must be in symbols/characters allowed like 0-9, A-Z, a-z, '_', '-', '@' and '.'

    is this possible ? I really need this, at the moment, user can put any characters or symbols (like chinese words or ☺☻♥♦♣♠•◘) in display name option in Profile, they can change to anything they want, I need to restrict that because their name will be in watermark text, it would be a joke if people can put any display name in videos

  6. Update: I did it, but like I said above, I only set watermark in 480p video format but it also watermark-ed in preview mode and other videos format even though I didn't set anything at all (attached picture above)

    Another (small) issue is the scrolling text is not smooth in 480p mode, it's like running at 10-15 fps (nothing wrong with video), is this fixable ?

     

  7. 11 hours ago, Tech Support said:

    This can be done. In video format settings you need to upload some "default" image for each watermark and set other options that you want (position, offset and etc). Then you can use these customization scripts to customize both watermarks. The first watermark is customized by the above kvs_watermark_video.php script.

    The 2nd watermark script is called kvs_watermark2_video.php, and its function name should be changed to kvs_watermark2_video as well.

    I tried, I can't make it work

    I did set "Customize watermark for content sources" for both of it

    image.png.380dde7470c16d135cf2e3cd8232276e.png

    Watermark (1) I chose my logo image, watermark2 I leave it empty because (I think) it generates text (uploaded by {{user}}) from kvs_watermark_video.php

    And I copied 2 files like this to /admin/include/

    image.png.2150010669e218528c012f1cf2e1c792.png

    Its code like yours above

    <?php
    
    function kvs_watermark_video($format_postfix, $video_data)
    {
       global $config;
    
       // here you should create and return image path with your custom watermark text
       // this file will be deleted, so you need to create it each time
    
       // check $format_postfix if you need watermark to be limited to specific formats only, e.g.
       // if ($format_postfix == '.mp4' || $format_postfix == 'trailer.mp4')
    
       // for example you can query user data and render "uploaded by <username>" watermark
       $user_data = mr2array_single(sql_pr("select * from $config[tables_prefix]users where user_id=?", $video_data['user_id']));
       if ($user_data['user_id'] > 0)
       {
           $watermark_file = "$config[temporary_path]/custom_watermark.png";
    
           // settings: text, font, size and offset
           $watermark_text = "This video was uploaded by $user_data[display_name] to XaTinh.com";
           $font = "$config[project_path]/admin/data/system/verdanab.ttf";
           $font_size = 10;
           $offset = 20;
    
           // rendering logic
           $box = imagettfbbox($font_size, 0, $font, $watermark_text);
    
           $im = imagecreatetruecolor(abs($box[2] - $box[0]) + 2 * $offset, abs($box[7] - $box[1]) + 2 * $offset);
           imagealphablending($im, false);
           imagefilledrectangle($im, 0, 0, abs($box[2] - $box[0]) + 2 * $offset, abs($box[7] - $box[1]) + 2 * $offset, imagecolorallocatealpha($im, 0, 0, 0, 127));
           imagealphablending($im, true);
    
           imagettftext($im, $font_size, 0, abs($box[0]) + $offset, abs($box[5]) + $offset, imagecolorallocate($im, 255, 255, 255), $font, $watermark_text);
    
           // save image to temp file
           imagesavealpha($im, true);
           imagepng($im, $watermark_file);
           imagedestroy($im);
    
           // return temp file back to KVS engine
           return $watermark_file;
       }
       return null;
    }

    Second kvs_watermark2_video.php

    <?php
    
    function kvs_watermark2_video($format_postfix, $video_data)
    {
       global $config;
    
       // here you should create and return image path with your custom watermark text
       // this file will be deleted, so you need to create it each time
    
       // check $format_postfix if you need watermark to be limited to specific formats only, e.g.
       // if ($format_postfix == '.mp4' || $format_postfix == 'trailer.mp4')
    
       // for example you can query user data and render "uploaded by <username>" watermark
       $user_data = mr2array_single(sql_pr("select * from $config[tables_prefix]users where user_id=?", $video_data['user_id']));
       if ($user_data['user_id'] > 0)
       {
           $watermark_file = "$config[temporary_path]/custom_watermark.png";
    
           // settings: text, font, size and offset
           $watermark_text = "This video was uploaded by $user_data[display_name] to xatinh.com";
           $font = "$config[project_path]/admin/data/system/verdanab.ttf";
           $font_size = 10;
           $offset = 20;
    
           // rendering logic
           $box = imagettfbbox($font_size, 0, $font, $watermark_text);
    
           $im = imagecreatetruecolor(abs($box[2] - $box[0]) + 2 * $offset, abs($box[7] - $box[1]) + 2 * $offset);
           imagealphablending($im, false);
           imagefilledrectangle($im, 0, 0, abs($box[2] - $box[0]) + 2 * $offset, abs($box[7] - $box[1]) + 2 * $offset, imagecolorallocatealpha($im, 0, 0, 0, 127));
           imagealphablending($im, true);
    
           imagettftext($im, $font_size, 0, abs($box[0]) + $offset, abs($box[5]) + $offset, imagecolorallocate($im, 255, 255, 255), $font, $watermark_text);
    
           // save image to temp file
           imagesavealpha($im, true);
           imagepng($im, $watermark_file);
           imagedestroy($im);
    
           // return temp file back to KVS engine
           return $watermark_file;
       }
       return null;
    }

     

    I only set watermark in 480p video format but it also watermark-ed in preview mode and other videos format even though I didn't set anything at all

    image.png.98ecd0c00258c6e0fb34b9a8308fae3e.png

     

    Could you please specific more how to do it?

    I'm appreciate your time and your support

  8. This is really weird, I'm thinking I got hacked, I only do few things and I got logout, but I login again it said incorrect password (No user found with such data)

    I've recovered through this guide: 

     

    The only thing I did change before I cannot login was relate to this topic

     

    I did replace font verdanaz.tff but I'm not sure it cause this or not, after that I restored by copy original verdanaz file from kvs zip file

     

    After recovered my admincp, I checked activity log in Administration tab but I didn't see any strange IP, what is the cause for this?

    I also check Audit and it shows this 

    image.png.4ef4e09c35263f0625c85f4b6636167b.png

     

    Right after I cannot login to admincp, the sidebar also not working, it closed by default instead open even though I tried to checked and unchecked it many times

    image.png.1e8bfbca701fa38dc99740e33fdbd849.png

     

    I need a big help please :(

    Does anyone experienced this? I tried to search but found nothing

  9. 12 hours ago, Alex69 said:

    Ok i found the solution, this is the code that works now , i mean now i can display avatares, and i can press ACCEPT REFUSE and is working:

     

    <div id="{{$block_uid}}">
    	<div class="headline">
    		<h2>
    			<a href="{{$lang.urls.memberzone_my_profile}}">{{$lang.memberzone.profile_my_title}}</a> /
    			{{assign var="profile_url" value=$lang.urls.memberzone_profile|replace:"%ID%":$conversation_user_id|replace:"%LOGIN%":$conversation_username}}
    			{{$lang.memberzone.profile_my_friendship_requests}}{{if $nav.page_now>1}}{{$lang.common_list.paginated_postfix|replace:"%1%":$nav.page_now}}{{/if}}
    		</h2>
    
    		<div class="sort">
    			<span class="icon type-edit"></span>
    			<strong>{{$lang.memberzone.messages_action_edit}}</strong>
    			<ul>
    				<li><a href="#delete" data-action="delete_conversation" data-user-id="{{$conversation_user_id}}" data-block-id="{{$block_uid}}" data-confirm="{{$lang.memberzone.messages_action_edit_delete_confirm|replace:"%1%":$conversation_display_name}}">{{$lang.memberzone.messages_action_edit_delete|replace:"%1%":$conversation_display_name}}</a></li>
    				<li><a href="#block" data-action="ignore_conversation" data-user-id="{{$conversation_user_id}}" data-block-id="{{$block_uid}}" data-confirm="{{$lang.memberzone.messages_action_edit_ignore_confirm|replace:"%1%":$conversation_display_name}}">{{$lang.memberzone.messages_action_edit_ignore|replace:"%1%":$conversation_display_name}}</a></li>
    			</ul>
    		</div>
    	</div>
    
    	<div class="box">
    		<div class="list-messages">
    			<div class="margin-fix" id="{{$block_uid}}_items" data-append-to-beginning="true">
    				{{if count($data)>0}}
    					{{assign var="pagination_use_load_more" value="false"}}
    					{{include file="include_pagination_block_common.tpl"}}
    
    					{{assign var="grouping_user_id" value=0}}
    					{{foreach name=data item=item from=$data}}
    						<div {{if $item.user_id==$smarty.session.user_id && $item.is_read==0}}data-autoscroll="true"{{/if}} class="item {{if $item.user_id!=$smarty.session.user_id}}me{{/if}} {{if $item.user_id==$smarty.session.user_id && $item.is_read==0}}new{{/if}} {{if $item.type_id==0 && $item.message==''}}deleted{{/if}} {{if $item.user_from_id==$grouping_user_id}}grouped{{/if}}" data-message-id="{{$item.message_id}}">
    							{{if $item.user_id==$smarty.session.user_id}}
    								<div class="image">
    									<a href="{{$lang.urls.memberzone_profile|replace:"%ID%":$item.user_from_id|replace:"%LOGIN%":$item.user_from_display_name}}">
    										{{if $item.user_from_avatar_url!=''}}
    											<img src="{{$item.user_from_avatar_url}}" alt="{{$item.user_from_display_name}}"/>
    										{{else}}
    											<span class="no-thumb {{if $conversation_gender_id==1}}male{{elseif $conversation_gender_id==2}}female{{elseif $conversation_gender_id==3}}couple{{elseif $conversation_gender_id==4}}trans{{/if}}"></span>
    										{{/if}}
    									</a>
    								</div>
    							{{/if}}
    							<div class="added {{if $item.user_id!=$smarty.session.user_id && $item.type_id==0 && $item.message!='' && $nav.is_first==1}}editable{{/if}}" {{if $item.user_id!=$smarty.session.user_id && $item.type_id==0 && $item.message!='' && $nav.is_first==1}}data-edit-message-id="{{$item.message_id}}"{{/if}}>
    								{{$item.added_date|date_format:$lang.global.date_format}}
    								{{if $item.user_id!=$smarty.session.user_id}}
    									{{if $item.is_read==0}}
    										{{$lang.memberzone.messages_unread}}
    									{{/if}}
    								{{/if}}
    							</div>
    							<div class="message-text">
    								{{if $item.type_id==0}}
    									{{if $item.message!=''}}
    										<span class="original-text">{{if $lang.enable_smileys=='true'}}{{$item.message|bbcode|replace:"\n":"<br>"}}{{else}}{{$item.message|replace:"\n":"<br>"}}{{/if}}</span>
    									{{else}}
    										{{$lang.memberzone.messages_deleted}}
    									{{/if}}
    								{{else}}
    									{{if $item.user_id==$smarty.session.user_id}}
    										{{$lang.memberzone.messages_system_types_received[$item.type_id]|replace:"%1%":$item.user_from_name|replace:"%2%":$smarty.session.display_name}}
    									{{else}}
    										{{$lang.memberzone.messages_system_types_sent[$item.type_id]|replace:"%1%":$smarty.session.display_name|replace:"%2%":$conversation_display_name}}
    									{{/if}}
    									{{if $item.message!=''}}
    										<span class="inline-text">{{if $lang.enable_smileys=='true'}}{{$item.message|bbcode|replace:"\n":"<br>"}}{{else}}{{$item.message|replace:"\n":"<br>"}}{{/if}}</span>
    									{{/if}}
    									{{if $item.type_id==1 && $item.user_id==$smarty.session.user_id}}
    										<form method="post" data-form="ajax">
    											<div class="bottom">
    												<input type="hidden" name="action" value="confirm_add_to_friends"/>
    												<input type="hidden" name="message_from_user_id" value="{{$item.user_from_id}}"/>
    												<input type="hidden" name="function" value="get_block"/>
    												<input type="hidden" name="block_id" value="{{$block_uid}}"/>
    												<input type="submit" class="submit" name="confirm" value="{{$lang.memberzone.btn_confirm}}"/>
    												<input type="submit" class="submit" name="reject" value="{{$lang.memberzone.btn_reject}}"/>
    											</div>
    										</form>
    									{{/if}}
    								{{/if}}
    							</div>
    						</div>
    						{{assign var="grouping_user_id" value=$item.user_from_id}}
    					{{/foreach}}
    				{{else}}
    					<div class="empty-content">{{$lang.memberzone.messages_no_data}}</div>
    				{{/if}}
    			</div>
    		</div>
    	</div>
    </div>

     

     

    My next question is how can i do to HIDE with a fading effect the ACCEPTED or REFUSED friendhsip request ? right now after pressign ACCEPT or REFUSE the request remain in the list till next page refresh ? Can you give me an idea how to do this ?

    Same, I also need this, not only hide fading effect but also Subscribe button or Unsubscribe button after click on it, it didn't change its value, like from "Subscribe" to "Subscribed" or "Unsubscribe" to "Subscribe" value after user clicked

  10. Is this available yet ?

    • Ability to reply comments (e.g. hierarchical comments)
    • User notification system, ability for users to get notifications about some events (new comments for their videos for example)

    Besides, it would be great if this could implemented

    Right now user won't know if there is any notification or not when they visit site until they hover or click to "hello, user" bar

    image.png.841c09e227d62a3b5670046afc419eee.png

    What if there's some notification and there's a sign for it ? Like this, user instantly know there's something for them. The (*) can be a number notification, but it should be red color or highlight color instead normal color

    image.png.78ef111d7849328c02d4fc647472d065.png

     

    And when they click to it, it will be like this

    image.png.c493ae531099cf60502e132133abf547.png

    Or a notification bell like facebook/youtube would be perfect, a small bell icon next to "Hello, user" bar

  11. May I ask what's the difference between:

    {{if $smarty.session.user_id>0}}href="{{$item.file_url}}"{{else}}href="{{$lang.urls.login_required}}" data-fancybox="ajax"{{/if}}

    And

    <a {{if $smarty.session.user_id>0}}href="{{$item.file_url}}&download_filename=mysite_{{$data.dir}}{{$item.postfix}}"{{else}}href="{{$lang.urls.login_required}}" data-fancybox="ajax"{{/if}} data-attach-session="{{$session_name}}">{{$lang.videos.video_details_label_download_format[$format_lang_key]|default:"%1%, %2%"|replace:"%1%":"`$item.title`"|replace:"%2%":$item.file_size_string}}</a>

    Which one should I use or is it the same?

  12. On 1/29/2021 at 12:36 PM, Tech Support said:

    Yes, it is possible but not via settings, but via template.

    In Website UI -> Pages -> View Video page -> video_view block template there is the following code to render download links:

    {{foreach item="item" from=$data.download_formats}}
    		{{assign var="format_lang_key" value=$item.postfix|replace:".":"_"}}
    		<a href="{{$item.file_url}}" data-attach-session="{{$session_name}}">{{$lang.videos.video_details_label_download_format[$format_lang_key]|default:"%1%, %2%"|replace:"%1%":"`$item.title`"|replace:"%2%":$item.file_size_string}}</a>
    {{/foreach}}

     

    What you should do is change this:

    href="{{$item.file_url}}"

    with this:

    {{if $smarty.session.status_id==3}}href="{{$item.file_url}}"{{elseif $smarty.session.user_id>0}}href="{{$lang.urls.upgrade}}" data-fancybox="ajax"{{else}}href="{{$lang.urls.login_required}}" data-fancybox="ajax"{{/if}}

     

    So KVS will still display download links, but if non-premium user clicks this link there will be either login dialog (user is not logged in), or upgrade dialog (user is not premium status) displayed.

    Luckily I found this topic, I was intend to create a new topic to ask exactly like this topic, how to enable download to only logged in members, thank you

  13. I'm facing a problem with uploading video files based on member positions.

    I've already tried adjusting the post_max_size and upload_max_file_ize settings in PHP, both in the PHP configuration and in the content settings of the KVS setup.

    However, members are still able to upload video files larger than the specified limits. Surprisingly, I haven't encountered any errors even when attempting to upload video files as large as 10 or 100GB. What could be the reason for this?

     

    Another issue I'm dealing with is limiting the character length during user registration. Is there a way to restrict the character count to a specific length?

    For example, if a user tries to register with a character count exceeding the limit, they should receive a message like "You have exceeded the allowed character limit. Please ensure it is below xx characters.", the registration process should prevent users from completing their registration until they shorten the number of characters. Is implementing this feature possible?

  14. 3 hours ago, Tech Support said:

    I guess this is because theme doesn't display this information. You can add the following:

    <div class="item">
    	Subscribers: <em>{{$data.subscribers_count}}</em>
    </div>

    somewhere into Website UI -> Page components -> include_member_profile.tpl template.

    Thank you, I got it

    Also please help my ticket

  15. I see there is amount number of people subscribe when I visit to another user, but when I go to my own Profile (or user go to their own), there is no amount of user subscribed to them

    Like this:

    image.png.a81d615b55346e4d49f34d7e5a8bc21a.png

     

    But when go to my own Profile, nothing shows about how many user subscribed

    image.thumb.png.0d235b3dca9b0f094e538514cee4d66f.png

     

    Is this because KVS hasn't updated yet ?

     

     

  16. 20 minutes ago, Tech Support said:

    This is related to storage server connection. You should also have error in admin panel in Settings -> Storage servers section. You can find out details in System audit plugin using servers check. There can be multiple causes:

    1. FTP server stopped working physically - in this case audit will report error that cannot connect
    2. FTP server software is not running (vsftpd in most cases) - in this case audit will report error that cannot connect
    3. Username / password changed - in this case audit will report error that cannot login
    4. FTP server has firewall restrictions and your primary server IP is not allowed - in this case audit will report error that cannot put / delete files
    5. FTP server is misconfigured and returns local IP in PASV command - in this case audit will report error that cannot put / delete files

    For issues #4 and 5 you may need to enable FTP command log in vsftpd config file to see what happens when KVS tries to connect to this server. Typically it will be clear what the issue is after reviewing this log file.

    In Storage servers it has an error: Content path is not writable

    What does this mean, I can manually upload and create files with ftp credentials, and I did not change login or password, I didn't change anything literally, it still working a week ago

  17. I have this error also related to video uploading

    Could you please check it

    [2023-05-25 22:35:06] INFO  Preparing task for conversion server [PH-P-2]
    [2023-05-25 22:35:06] INFO  Conversion priority level is set to 0
    [2023-05-25 22:35:06] INFO  Video formats will be created: "MP4  480p", "MP4  720p", "MP4 1080p", "MP4 4k", "MP4 Preview"
    [2023-05-25 22:35:06] INFO  Video files will be post-processed: none
    [2023-05-25 22:35:06] INFO  Timeline screenshots will be created for video formats: "MP4  480p"
    [2023-05-25 22:35:06] INFO  Video main screenshot has been uploaded: 640x360
    [2023-05-25 22:35:06] INFO  Sources for overview screenshots will be created
    [2023-05-25 22:35:06] WARN  Failed to connect to storage server "Storage Frankfurt", skipping this task

    There have been hundreds of previous videos that were successfully uploaded, but as time went on, this error started to occur to a lot of videos, I use grabber to make it download to ftp server and system processing it from main server, I did check ftp server and I can still login in with ftp credentials and I can manually upload or create files.

×
×
  • Create New...