Fork me on GitHub

[Solution] compatibility of PN_zClassifieds module with mysql5  Bottom

Go to page 1 - 2 [+1]:

  • Hello,
    My provided has recently upgraded my website to both php5 and mysql5.
    This has revealed a problem in some SQL queries of the corrected version of the Technivore PN-zClassifieds module that you can download from my website http://www.vedrine.net in the Downloads section.
    As I don't know if I willl find the time to update the zip file, here is the change to do to correct the problem. You only need to add some parenthesis.
    in the PN_zClassifieds/index.php, change lines 148-149 from:

    Code

    $sql .= " FROM ".$prefix."_classifieds_ads , ".$prefix."_classifieds_category";
            $sql .= " LEFT JOIN ".$prefix."_classifieds_country ON (country_id=id)  ";

    to:

    Code

    $sql .= " FROM (".$prefix."_classifieds_ads , ".$prefix."_classifieds_category";
            $sql .= ") LEFT JOIN ".$prefix."_classifieds_country ON (country_id=id)  ";

    You have to do exactly the same change in the PN_zClassifieds/search.php lines 84-85 and lines 197-198
    Please this only apply to the version you can download from my website, original Technivore version has other problems with mysql5

    --
    Visit my live reef aquarium.

    My Amazon wish list.
  • Thank you very much for this!

    thanks,
    json
  • Hi, I have performed the above fix on index.php and search.php and PN_zClassifieds is now (partially) working - the ads can be viewed and searched. However, when a new ad is added or an existing ad edited the following error message is displayed:

    Code

    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 'condition='', exp_date=exp_date+0, country_id='0', state_id='0', valid='1', moth' at line 1


    Any idea as to what SQL statements need changed?

    Regards

    Robbie


  • Hi there Robbie,

    I found the solution here. Basically, the row name "condition" is a reserved name in MySQL 5 and it must be changed. After making the changes in the files listed and the classifieds database, I am once again able to submit ads.

    Hope this helps you,
    json
  • Thanks so much - followed the instructions and it now works.

    Much appreciated.

    Robbie
  • No problem at all. I'll probably package it and put it up for distribution somewhere. That's the downside to FOSS compared to commercial apps. Often, as the devs see the next shiny object on the horizon, they don't feel as strong an attachment to the current project as they would if they were getting paid for it :)

    thanks,
    json
  • Please, post the link when you have the package somewhere icon_wink
    TIA

    --
    - Mateo T. -
    Mis principios... son mis fines
  • Does anyone have a clean zip of the download that was available on his site? I can cobble what I have together, but I was hoping to have a fresh installable zip to modify and he no longer has a download section on his site.

    thanks,
    json
  • Hello,
    There is still a download section on my website and I have published a version to enhance compatibility with zikula (with a pnsearchapi.php file). you can found it here http://www.vedrine.n…display-lid-37.html, it has the correction for mysql5 applied.

    --
    Visit my live reef aquarium.

    My Amazon wish list.
  • I'm trying to download from your site, but even after registering I didn't find the link to donwload... I'm using firefox

    --
    Together We Are More Than Winners
  • forgive me... I just got it in your site... I think I was blind

    --
    Together We Are More Than Winners
  • how can I get currencies in my country format, for example: instead 12,590.00 ==> 12.590,00

    --
    Together We Are More Than Winners
  • Hello,
    As my site is now running Zikula 1.1.2 I have upgraded quite a lot of modules including the Downloads module and as a result a lots of URL posted in these forums in the past aren't working anymore.
    But the files are still available (even if I plan to remove in the future all the files not working with Zikula)
    In the process I have modified all old modules that I use (anniversaire, cards, PN_zClassifieds, pnFlashGames) to enhance compatibility.
    I need some time to post the new versions in the Downloads section but feel free to ask if you need one these versions quickly.
    For PN_zClassifieds, I only made some patches to be able to wait a new totaly rewritten version that I plan to work on one day.
    For your currency problem I seem to remember there was a file to edit to do what you want but I need to look at the code to be able to help you. Remember that I am not the original author of this module.

    --
    Visit my live reef aquarium.

    My Amazon wish list.
  • I'm not sure if the link you posted above is up to date or obsolete. Does it include the patches you just refer to or not? If not, I would *really* appreciate it if the patches were available. I'd suggest you just post the latest of what you have into the Cozi.
  • No for the moment the version used converting www.vedrine.net to Zikula aren't available anywhere.
    I intend to ask for creation of Cozi projects and make available the current state in SVN at first and do a release when I reach a some stability (for the moment I corrrect problems and bugs each day !!)
    If you found anything not working as it should on http://www.vedrine.net, please report to me.

    --
    Visit my live reef aquarium.

    My Amazon wish list.

Go to page 1 - 2 [+1]:

This list is based on users active over the last 60 minutes.