Advertisement:

Author Topic: Watchlist pluggin done !  (Read 32211 times)

RajaSekar

  • Hero Member
  • *****
  • Posts: 791
  • ராஜசேகர்
Re: Watchlist pluggin done !
« Reply #30 on: October 02, 2011, 09:33:40 am »
Hi hunt4it

Place this code at the end of themes style.css file

globexcam

  • Jr. Member
  • **
  • Posts: 58
  • get what you want
Re: Watchlist pluggin done !
« Reply #31 on: October 02, 2011, 02:46:33 pm »
Hi friends

I installed the watchlist plugin.
IT shows on the dashboard but i can't see it on items.

where should i put this code: "<p align="right"><?php watchlist();?><p>"


I am using the Bcute them please!!

Please tell me what to do next.

Thanks !!!

RajaSekar

  • Hero Member
  • *****
  • Posts: 791
  • ராஜசேகர்
Re: Watchlist pluggin done !
« Reply #32 on: October 02, 2011, 06:29:20 pm »
@globexcam

locate these line in item.php

Code: [Select]

<strong class="share"><a href="<?php echo osc_item_send_friend_url() ; ?>" rel="nofollow"><?php _e('Share''modern') ; ?></a></strong>


Replace the above line with this

Code: [Select]

<strong class="share"><a href="<?php echo osc_item_send_friend_url() ; ?>" rel="nofollow"><?php _e('Share''modern') ; ?></a></strong>
<strong class="share"><?php watchlist(); ?></strong>


nextpuma

  • Jr. Member
  • **
  • Posts: 62
Re: Watchlist pluggin with non registed user
« Reply #33 on: November 01, 2011, 01:42:35 am »
how can i make this plugin work with non register user to?

diego_tucholga

  • Jr. Member
  • **
  • Posts: 51
Re: Watchlist pluggin done !
« Reply #34 on: November 15, 2011, 02:03:21 pm »
Hi,

thanks for sharing that plugin, it´s that what I searched for.
But I have two problems:
1.) The watchlist only does his job on the first time, if I click now on 'add to watchlist', it doesn´t do anything
2.) On the first time (When the submit works) I only came to the start page (wheter I clicked on watch watchlist), but the url looks like page.php?name=custom... this.

send4radha

  • Newbie
  • *
  • Posts: 40
Re: Watchlist pluggin done !
« Reply #35 on: November 16, 2011, 01:52:42 pm »
Watchlist pluggin works fine to all.

Parse error: parse error in D:\wamp\wamp\www\osclass223\oc-content\plugins\watchlist\ajax_watchlist.php on line 33

Can you please help me on this.

Diablos

  • Full Member
  • ***
  • Posts: 127
Re: Watchlist pluggin done !
« Reply #36 on: January 19, 2012, 08:29:59 pm »
Why my ads have a "t" at the end of title??

tnx http://compro-vendo.org

Cris

  • Full Member
  • ***
  • Posts: 125
Re: Watchlist pluggin done !
« Reply #37 on: April 05, 2012, 04:50:20 am »
Hello!

i've fixed some problems! the old function watchlist() alway show "Add to watchlist", but now: 
if you are not logged in -> message is "Please Login"
if you are logged in -> message is "Add to watchlist"
if ad is in watchlist -> message is  "Is in my watchlist"

here is the function:
Code: [Select]
function watchlist() {
        $id    = Params::getParam('id');
    if ( osc_is_web_user_logged_in() ) {
            //check if the item is not already in the watchlist
            $conn   = getConnection();
            $detail = $conn->osc_dbFetchResult("SELECT * FROM %st_item_watchlist WHERE fk_i_item_id = %d and fk_i_user_id = %d", DB_TABLE_PREFIX, $id, osc_logged_user_id());

            //If nothing returned then we can process
            if (!isset($detail['fk_i_item_id'])) {
                           
                    echo '<a href="javascript://" class="watchlist" id="' . osc_item_id() . '">' ;
        echo '<span>' . __('Add to watchlist', 'watchlist') . '</span>' ;
        echo '</a>' ;

               
            }
else
{
                //Already in watchlist !
                echo '<span align="left"><a href="' . osc_base_url(true) . '?page=custom&file=watchlist/watchlist.php">' . __('Is in my watchlist','watchlist') . '</a></span>';
            }
        }
else {
            //error user is not login in
            echo '<a href="' . osc_user_login_url() . '">' . __('Please login', 'watchlist') . '</a>';
        }

   
    }
« Last Edit: April 05, 2012, 04:53:19 am by Cris »

Karsus

  • Newbie
  • *
  • Posts: 7
Re: Watchlist pluggin done !
« Reply #38 on: May 04, 2012, 05:42:18 pm »
Hello.
I want to suggest a feature.
If an item of watchlist change, 'cause the owner change the price/description/availability etc. etc., it would be nice if the user who have this item in the watchlist can receive an alert about the event.

Do you think this is possible?

Noosa

  • Jr. Member
  • **
  • Posts: 55
Re: Watchlist pluggin done !
« Reply #39 on: May 31, 2012, 04:23:20 pm »
Watchlist pluggin works fine to all.

Parse error: parse error in D:\wamp\wamp\www\osclass223\oc-content\plugins\watchlist\ajax_watchlist.php on line 33

Can you please help me on this.

This error, PHP Parse Error: syntax error, unexpected $end, is most likely caused by the use of 'short open tags'. Verify the opening tags are <?php and not <? (short open).

astroboy

  • Newbie
  • *
  • Posts: 46
Re: Watchlist pluggin done !
« Reply #40 on: July 04, 2012, 12:29:47 pm »
Great plugin! thanks for taking the time to produce this, I have a small problem however.

It all works fine, if I add the item to the watchlist the button changes to "View your watchlist" but, if I refresh the page it will say "Add to watchlist" even though it's already added.

I have this in the ajax_watchlist.php
Code: [Select]
<?php

    
if (Params::getParam('id') != '') {
        
$id    Params::getParam('id');
        
$count 0;

        if ( 
osc_is_web_user_logged_in() ) {
            
//check if the item is not already in the watchlist
            
$conn   getConnection();
            
$detail $conn->osc_dbFetchResult("SELECT * FROM %st_item_watchlist WHERE fk_i_item_id = %d and fk_i_user_id = %d"DB_TABLE_PREFIX$idosc_logged_user_id());

            
//If nothing returned then we can process
            
if (!isset($detail['fk_i_item_id'])) {
                
$conn getConnection();
                
$conn->osc_dbExec("INSERT INTO %st_item_watchlist (fk_i_item_id, fk_i_user_id) VALUES (%d, '%d')"DB_TABLE_PREFIX$idosc_logged_user_id());
                
?>

                <span align="left">
                    <a href="<?php echo osc_base_url(true); ?>?page=custom&file=watchlist/watchlist.php">
                        <?php _e('View your watchlist''watchlist'?>
                    </a>
                </span>
                <?
            } else {
                //Already in watchlist !
                echo '<span align="left"><a href="' . osc_base_url(true) . '?page=custom&file=watchlist/watchlist.php">' . __('View your watchlist', 'watchlist') . '</a></span>';
            }
        } else {
            //error user is not login in
            echo '<a href="' . osc_user_login_url() . '">' . __('Please login', 'watchlist') . '</a>';
        }
    }

?>

I tried with both permalinks on and off but same result.

Have this in item.php
Code: [Select]
                    <p class="contact_button">
                        <?php if( !osc_item_is_expired () ) { ?>
                        <?php if( !( ( osc_logged_user_id() == osc_item_user_id() ) && osc_logged_user_id() != ) ) { ?>
                            <?php     if(osc_reg_user_can_contact() && osc_is_web_user_logged_in() || !osc_reg_user_can_contact() ) { ?>
                                <strong style="float:right; margin-right:140px; margin-top:-40px; padding-bottom:8px;"><a href="#contact"><?php _e('Contact seller''modern') ; ?></a></strong><br />
<strong style="float:right; margin-top:-55px; padding-bottom:8px;"> <a href="#watchlist"> <?php watchlist(); ?></strong>
                            <?php     ?>
                        <?php     ?>
                        <?php ?>
                    </p>

Please help.

texthiller

  • Full Member
  • ***
  • Posts: 207
Re: Watchlist pluggin done !
« Reply #41 on: August 23, 2012, 01:11:55 am »
Hi! When click on add to watch list this is the error:


( ! ) Parse error: syntax error, unexpected $end in oc-content\plugins\watchlist\ajax_watchlist.php on line 33
Call Stack
#   Time   Memory   Function   Location
1   0.0011   438088   {main}( )   ..\index.php:0
2   1.0880   12280448   CWebAjax->doModel( )   ..\index.php:111
« Last Edit: August 28, 2012, 01:01:53 pm by texthiller »

yammy

  • Newbie
  • *
  • Posts: 24
I wrote a pt_BR translation for your plugin
« Reply #42 on: September 30, 2012, 05:57:47 am »
Hello !

Today I downloaded your plugin and translated it to pt_BR, please tell me when you add this to the original download site, so I can check this tell-author todo from my list : )


Thanks

[]s

anypis

  • Newbie
  • *
  • Posts: 18
Re: Watchlist pluggin done !
« Reply #43 on: November 03, 2012, 12:54:34 am »
Does anybody know how to fix css problem on user menu on realestate template?

soluoma

  • Newbie
  • *
  • Posts: 10
Re: Watchlist pluggin done !
« Reply #44 on: February 12, 2013, 02:12:57 am »
Can anyone help me with issue I'm having with the watchlist feature.

The watchlist button partially disappears when clicked and does not add the item to my watchlist.

Cheers,
Stan