• Content count

  • Joined

  • Last visited


About Valtasar

  • Rank
    IPB Full Member

IPS Marketplace

  • Resources Contributor Total file submissions: 2

Valtasar's Activity

  1. Valtasar added a post in a topic: Please Revert the Moderating Team Page   

    One very simple change to admin/applications/forums/modules_public/extras/stats.php to sort the groups, e.g. for IPB 3.3.4 is:

    Line: 378 Change: 'select' => 'm.*, m.member_id as my_member_id' To: 'select' => 'm.*, m.member_id as my_member_id,field(m.member_group_id,4,6,14,9,7,12) as group_sort' and Line 395: From: 'order' => 'm.members_display_name', To: 'order' => 'group_sort,m.members_display_name',

    where 4,6,14,9,7,12 are the group IDs for my custom moderating team, i.e. 4 is the Root admin, 6 is Admin, 9 is Global Mod, 7 Mod etc. Be sure to list all IDs of your team there, otherwise the unknown IDs are listed first.
  2. Valtasar added a record in IP.Board   

    Permissions and forum follow issue
    I run 3.2.3 and I just confirmed a similar issue (as the already discussed/fixed issue #031098 for "topic following") for "forum following": Email notifications for new topics in the forum are still emailed to me, even if I don't have access to the forum anymore. The issue for "topic following" is indeed fixed as reported (I did get an email notification at all).

    PS: And two more related issues: in both cases (topic or forum following) I still appear to other people as still following the forum (or topic) even after my access to them is removed. As I see the entries in ibf_core_like table are still there, but I can understand that this may be difficult to fix, since you probably need to check all followed topics/forums by a member whenever his access properties are somehow changed.
    • 0 replies
  3. Valtasar added a comment: Reputation in query causing issues (cont.)   

    Note: [url=""]rows_sent[/url] and [url=""]rows_examined[/url] for these queries were small numbers.
    Does this mean everything is fine with these queries?
    If so, please ignore the issue: I suspect the real issue of the slow queries is something else, since as I now see I really had a lot of slow queries during this high load period.
  4. Valtasar added a record in IP.Board   

    Reputation in query causing issues (cont.)
    I recently experienced some high loads for a few times so I activated slow query logging in mysql. In the slow logs I have many entries like the following:
    SELECT p.*,m.member_id as mid,,m.member_group_id,,m.joined,m.posts, m.last_visit, m.last_activity,m.login_anonymous,m.title as member_title, m.warn_level, m.warn_lastwarn, m.members_display_name, m.members_seo_name, m.has_gallery, m.has_blog, m.members_bitoptions,m.mgroup_others,m.topics_started,m.bday_day,m.bday_month,m.bday_year,pp.*,pc.*,rep_index.rep_rating as has_given_rep,rep_cache.rep_points, rep_cache.rep_like_cache,cca.*,ccb.cache_content as cache_content_sig, ccb.cache_updated as cache_updated_sig FROM ibf_posts p LEFT JOIN ibf_members m ON ( m.member_id=p.author_id )
    LEFT JOIN ibf_profile_portal pp ON ( m.member_id=pp.pp_member_id )
    LEFT JOIN ibf_pfields_content pc ON ( pc.member_id=p.author_id )
    LEFT JOIN ibf_reputation_index rep_index ON ('forums' AND
    rep_index.type='pid' AND AND
    rep_index.member_id=23772 )
    LEFT JOIN ibf_reputation_cache rep_cache ON ('forums' AND rep_cache.type='pid' AND )
    LEFT JOIN ibf_content_cache_posts cca ON ( )
    LEFT JOIN ibf_content_cache_sigs ccb ON ( ccb.cache_content_id=m.member_id ) WHERE IN(212661,212678,212969,213138,213774,213894,213897,213898,213900,213951,213967,213969,213970,213973,213975,213976,213977,213978,213990,213994,213997,213999,214000,214001,214004,214023,214500,214504,214576) ORDER BY pid asc

    which as I see matches exactly this issue:
    Is there anything I can do/check to solve this?
    I see the "app" index in the ibf_reputation_cache table (mentioned by bfarber in the other issue) exists and as I see it is unique.
    • 0 replies
  5. Valtasar added a comment: Sphinx Template   

    The above changes are correct, and lead to no errors in indexer but searchd returns:

    WARNING: index 'downloads_comments_main': duplicate attribute name: file_id
    WARNING: index 'downloads_comments_delta': duplicate attribute name: file_id

    It's probably due to the fact that file_id exists in both ibf_downloads_files and ibf_downloads_ccontent.
    Is there any nice way to handle this and avoid this warning (except deleting file_id completely as an attribute for downloads_comments)?
  6. Valtasar added a comment: Minor detail I noticed at search code   

    I now see it's the other way around: what I spotted as a bug may well be the only correct line in that piece of code )

    foreach( $data as $field => $_data )
    /* CONTENT ONLY */
    if ( $field == 'noPreview' AND $_data['noPreview'] == 0 )
    IPSSearchRegistry::set( 'opt.noPostPreview', false );
    /* POST COUNT */
    if ( $field == 'pCount' AND intval( $_data['pCount'] ) > 0 )
    $return[] = array( 'column' => 't.posts', 'operator' => '>=', 'value' => intval( $_data['pCount'] ) );
    /* TOPIC VIEWS */
    if ( $field == 'pViews' AND intval( $_data ) > 0 )
    $return[] = array( 'column' => 't.views', 'operator' => '>=', 'value' => intval( $_data['pViews'] ) );
    Since $_data is scalar and $data is the array, all $_data elements are wrong: they either should be converted to $_data or to $data['...'].
    Same holds for the $sphinx.php file.
  7. Valtasar added a record in IP.Board   

    Minor detail I noticed at search code
    In admin/applications/forums/extensions/search/engines/sphinx.php, line 931 I think it should be:

    [CODE] if ( $field == 'pViews' AND intval( $_data['pViews'] ) > 0 )[/CODE]

    instead of:

    [CODE] if ( $field == 'pViews' AND intval( $_data ) > 0 )[/CODE]

    A similar change is probably needed in the same function in admin/applications/forums/extensions/search/engines/sql.php
    • 0 replies
  8. Valtasar added a comment: Random Capitalization of letters in the text   

    OK, but no need to add any 2-letter entities like "lt", "gt" in your $notList ?
  9. Valtasar added a comment: HTML email problem with quoted Greek utf8 text   

    See my related post in Issue #033979, which probably solves this issue.
  10. Valtasar added a comment: Random Capitalization of letters in the text   

    Matt, I am afraid this convertTextEmailToHtmlEmail function in admin/sources/base/core.php has created huge problems with Greek letters that have 2-letter codes as html entities, namely: 'Μ','Ν','Ξ','Π','μ','ν','ξ','π'. which as I see are up today ALWAYS stored as html entities in the posts table in my board. I think I fixed this problem as follows (see also [url=""]here[/url] ). I don't like this at all, since I believe it may also affect searches (does it?) plus it does not look good in phpmyadmin, so please check and confirm that my fix is fine:

    public static function decodeNamedHtmlEntities( $string )
    preg_match_all( '#&([^;\s]+?);#', $string, $matches );
    $entities = array();
    $notList = array( 'amp' );
    $inList=array( 'Μ','Ν','Ξ','Π','μ','ν','ξ','π' );//line added by Valtasar

    foreach( $matches[0] as $word )
    if ( preg_match( '#^&([a-zA-Z]{3,8});$#', $word, $match ) )
    if ( ! in_array( $match[1], $notList ) )
    $entities[] = $word;
    //following added by Valtasar
    else if ( in_array( $word, $inList ) )
    $entities[] = $word;

    However, even if this is fine for Greek, I believe what to avoid similar errors with Math symbols and entities from other languages, you should really make the preg_match [2,8] to replace 2-letter words too and then add to your $notList all UNDESIRED words (like "< etc" as you write). Are these so many, that you cannot list them there?
  11. Valtasar added a record in IP.Board   

    HTML email problem with quoted Greek utf8 text
    I activated HTML emails, and although I receive properly HTML emails, some Greek characters ONLY within QUOTED text, are converted to html entities.
    See below a test email with a quote containing the Greek alphabet:

    ------------ QUOTE ----------

    αβγδεζηθικλμνξοπρστυφχψω άέίύόώ ϊ


    This is reply!!!!
    The above shows that the problem concerns ONLY the following Greek characters:

    &mu, &nu, &xi and &pi.

    All the others are fine. My board is using utf-8 encoding.
    • 0 replies
  12. Valtasar added a comment: Upgrade failures on app_website   

    I'm sorry! It's actually 3.0.3 => 3.2.1 and then 3.2.1 => 3.2.3
  13. Valtasar added a comment: Upgrade failures on app_website   

    I got this error when I tried to convert my board from 3.0.3 to 3.2.3.
    I managed to complete update by doing two steps: 3.0.3 => 3.2.2 and then 3.2.2=>3.2.3.
  14. Valtasar added a comment: Driver error on 3.2.3 fresh install   

    Could be that in some MySQL versions utf8 may require 4 bytes! Check here: and here:
  15. Valtasar added a record in IP.Board   

    Uploading large jpg images as attachments
    I observed strange behaviour when I tried to upload a large jpg image (e.g. 7000x3000) as an attachment (the image in upload folder but 500 error messages are created and
    the attachment is not generated).
    Tracing the problems in the code showed that the problem is in the function "imagecreatefromjpeg" (in ips_kernel/classImageGd.php), which hangs for large images!
    This function is called a) to resize a big image and/or b) to create the thumbnail for it.
    This GD issue has been reported, e.g. here:

    Bfarber has solved a similar problem here:
    so I wonder if he can somehow apply that solution here.
    If not, I would suggest (at least) to have some upper width/heigh limits in the code or in ACP (that allow imagecreatefromjpeg to work fine) and then dispaly an error message to a user that tries to upload an attachment that is higher than this limit.
    • 0 replies