Aller à la page: 1 - 2 [+1]

Fin
two problems in pn_zclassifieds
  • Envoyé: 01.11.2006, 05:08
    Invité
    rang:
    1
    enregistré depuis:
     décembre 2003
    Status:
    hors ligne
    dernière visite:
    06.03.05
    Messages:
    0
    Hi there,

    I have two problems with pn_zclassifieds.

    1) Block: When I choose to show wanted and for sale, only the for sale section shows in the block. How do I make it show both?

    2) People often confuse "suggest a category" with "suggest an ad". How do I change "suggest an ad" to "create an ad"?

    thanks,
    json
  • Envoyé: 01.11.2006, 09:41
       
    vedrine
    rang:
    Site Admin Site Admin
    enregistré depuis:
     décembre 2003
    Status:
    hors ligne
    dernière visite:
    12.05.08
    Messages:
    257
    Hello,
    1)
    First thing to know is that blocks in my version have been rewritten to work with recent PostNuke versions and so that the files can be in the modules/PN-zClassifieds/pnblocks subdirectory. The situation is completely different with original blocks from Technivore so the first thing to do is to check that you don't have old Technivore versions of the blocks in your includes/blocks directory and if you find such files, to delete them.
    There are 5 different blocks in my version here are the names that are displayed when you create a new block and when you look at the activated block's list, and also the name of the file for that block:






    PN_zClassifieds featured ad blockPN_featured_adfeatured_ad.php
    zclassifieds last ads by catlastads_bycatlastads_bycat.php
    zclassifieds last ads by typelastads_bytypelastads_bytype.php
    zclassifieds last ads imageslastads_imglastads_img.php
    PN_zClassifieds ads/cats blockzclassifiedszclassifieds.php

    First thing I need to be sure is thee one you are having a problem with.
    I guess it is the zclassifieds last ads by type block becaus eit is the only one where you can select the type of the ads to display. I will look at the code to see if I find any bug or typo.
    2)
    In the modules/PN_zClassifieds/lang/eng/global.php change the line:
    define('_SUGGESTADS', 'Suggest an ad');
    to:
    define('_SUGGESTADS', 'Create a new ad');
  • Envoyé: 01.11.2006, 15:02
       
    vedrine
    rang:
    Site Admin Site Admin
    enregistré depuis:
     décembre 2003
    Status:
    hors ligne
    dernière visite:
    12.05.08
    Messages:
    257
    Well in fact there were at least 2 bugs in the ads by type block preventing it from displaying both wanted and for sale ads, and also only half of the ads were displayed for each type due to a duplicated line !!
    I have now corrected the zip archives in the downloads section of this website.
    Please report any other problem on this forum.
    Thanks for reporting these bugs.
  • Envoyé: 06.11.2006, 02:47
    Invité
    rang:
    1
    enregistré depuis:
     décembre 2003
    Status:
    hors ligne
    dernière visite:
    06.03.05
    Messages:
    0
    Hi there vedrine,

    Thanks very much for correcting the blocks. I'm going to download it now and give it a shot. I appreciate you looking at it very much!

    thanks,
    json
  • Envoyé: 06.11.2006, 03:33
    Invité
    rang:
    1
    enregistré depuis:
     décembre 2003
    Status:
    hors ligne
    dernière visite:
    06.03.05
    Messages:
    0
    I think I might have tried to update it incorrectly. Either that, or I've found a bug :)

    PN .762
    First, I tried to overwrite latest(by type), and I got an error. Then I deleted the original block, and reinstalled the new one. I get the same error.

    This is what shows up in place of the block:

    Citation
    database error query:SELECT ad_id, cat_id, subject, price FROM , WHERE root_id=cat_id AND (lang='eng' OR lang='') AND exp_date>1162783677 AND valid=1 AND type = 0 ORDER BY add_date DESC LIMIT 5 error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ' WHERE root_id=cat_id AND (lang='eng' OR lang='') AND exp_date>1162783677 AND v' at line 1


    Reinstalling the original block works fine.

    thanks,
    json
  • Envoyé: 06.11.2006, 07:07
       
    vedrine
    rang:
    Site Admin Site Admin
    enregistré depuis:
     décembre 2003
    Status:
    hors ligne
    dernière visite:
    12.05.08
    Messages:
    257
    Hello,
    The error message explains the problem: the table names are missing, should be "SELECT ad_id, cat_id, subject, price FROM nuke_classifieds_ads, nuke_classifieds_category WHERE ..."
    But I don't see why the table names are missing.
    Everything is working as expected on my test site.
    verify that you have a correct pntables.php file in your modules/PN_zClassifieds directory (but it should be there because the older version is working !)
    The strange thing is that I made no change in that part of the code !!
  • Envoyé: 06.11.2006, 14:57
    Invité
    rang:
    1
    enregistré depuis:
     décembre 2003
    Status:
    hors ligne
    dernière visite:
    06.03.05
    Messages:
    0
    Hi there vedrine,

    the tables are there. If I create the new block(with the updated code), I get the error, however if I replace the new block back with the old one, it begins working again, so the tables are there, the new block just isn't finding it.

    thanks,
    json
  • Envoyé: 06.11.2006, 16:07
       
    vedrine
    rang:
    Site Admin Site Admin
    enregistré depuis:
     décembre 2003
    Status:
    hors ligne
    dernière visite:
    12.05.08
    Messages:
    257
    Hi,
    the problem isn't the tables themselves. I know the tables are there because your module is working.
    To find the table the block need a (correct) modules/PN_zClassifieds/pntables.php file .
    The module itself doesn't need the modules/PN_zClassifieds/pntables.php file to work because it is very outdated and badly written code. But as the block is brand new code it absolutely need this file.
    Can you check that this file modules/PN_zClassifieds//pntables.php is present on your server ?
    If you are unsure if your pntables.php is OK, I can send you a verified one (I just find a typo between PN_zClassifieds and PN_ZClassifieds in some files so better to verify).
    Just send me your mail address to vedrine _AT_vedrine _DOT_ net if you want this file.
    Using the old block isn't an option because there were several bugs in it.
  • Envoyé: 06.11.2006, 16:25
    Invité
    rang:
    1
    enregistré depuis:
     décembre 2003
    Status:
    hors ligne
    dernière visite:
    06.03.05
    Messages:
    0
    Hi there vedrine,

    I don't have that file. I've sent you an email. Thank you very much for taking the time to help.

    thanks,
    json
  • Envoyé: 07.11.2006, 15:24
    Invité
    rang:
    1
    enregistré depuis:
     décembre 2003
    Status:
    hors ligne
    dernière visite:
    06.03.05
    Messages:
    0
    Hi there vedrine,

    I checked the download of pn_zclassifieds, and it doesn't have a pntables.php in the module's directory either. Should it have?

    thanks,
    json

Aller à la page: 1 - 2 [+1]

Réponse rapide
 
  • Options
Code:
Couleur de la police:  
Taille de la police: