Main
Index
Search
Posts
Who's
Online
Log
In

Home: Discontinued/Classic Products: Listings Manager (Realty Manager & Auto Manager):
Incorrect images displayed for preview image

 

 


Fredx
User

Apr 4, 2008, 11:02 AM

Post #1 of 9 (3853 views)
Shortcut
Incorrect images displayed for preview image Can't Post

Hi, folks:

The client for this installation of realty listings manager has repeatedly encountered problems where incorrect - and even deleted - images display. This is likely due to inappropriate custom coding in the _publish_listing.html template.

For example, under admin for the listing 6908 David Lane,
preview image = 'front good'
image#1 = 'garage doors'
image#2 = 'study ceiling'
image#3 = 'elevation'. That's it.

There are other images in the database. One is 'gable'.

Now when one views the listing catalog via the listing manager, the 'front good' preview thumbnail is correctly displayed. However, when the full listing page is brought up, the 'gable' image is displayed as the default image. It should be 'front good'.

----

Viewing the source for 6908 David Lane, the main image is 'listman/listings/images/24_1.jpg'. This is generated by the _publish_listing.html template directive
<img name="mainPhoto" id="mainPhoto" src="$listing_url_je$/images/$listing_num_he$_1.jpg" alt="" align="center">

This probably is incorrect. The objective is to show the image that has been selected as the 'preview image', in this case: 'front good', which is currently 'listman/listings/images/24_5.jpg'.

----

Note on image ordering: the client's office will initially add the listing and some photos. They will go back and change a few images and reselect a new preview image. Thus, the first photo may or may not be the preview image. Indeed, they may have completely deleted the first photo uploaded.

How do I specify the currently specified preview image in the template?

Thanks,

Fred


Jake
Staff / Moderator


Apr 7, 2008, 2:42 PM

Post #2 of 9 (3830 views)
Shortcut
Re: [Fredx] Incorrect images displayed for preview image [In reply to] Can't Post

Hi Fred,

Thanks for posting.

As you suspected, the line of code used on your template to display the image is incorrect. The link is hardcoded in such a way as to always display the first image uploaded, regardless of whether this is the preview image or not. Try using this code instead:


Code
<img name="mainPhoto" id="mainPhoto" src="$listing_url$/images/$file$" alt="" align="center">


It looks like the image link may have been set up like that to accommodate some kind of image script. If you're using any special image scripts, this change could disrupt their functionality.

Let us know if you need anything else. Smile
-----------------------------------------------------------
Cheers,
Jake Marvin - Product Specialist
support@interactivetools.com

[hr][i][url "http://www.interactivetools.com/consulting/"][b]Hire me![/b][/url]
Save time by getting our experts to help with your project. Template changes, advanced features, full integration, whatever you need. Whether you need one hour or fifty, get it done fast with [url "http://www.interactivetools.com/consulting/"][b]Priority Consulting[/b][/url].[/i]


Fredx
User

Apr 7, 2008, 4:38 PM

Post #3 of 9 (3827 views)
Shortcut
Re: [Jake] Incorrect images displayed for preview image [In reply to] Can't Post

Hi, Jake:

Thanks for the snippet. I tried the code and nothing different happened. I changed cgi-bin/listman/templates/_realty/_publish_listing.html.

Then , under admin, I republished all listings. Then I cleared cache and did a force reload of the listing. No changes.

So I changed /images/ to /images_rats/ in the code and repeated the above. I would have expected to see no images. But... No changes!

Am I modifying the wrong template? Suggestions?

(Yes, I'm using some javascript to change the image when the user mouses over subsequent thumbnails).

Thanks,

Fred


Jake
Staff / Moderator


Apr 8, 2008, 2:06 PM

Post #4 of 9 (3798 views)
Shortcut
Re: [Fredx] Incorrect images displayed for preview image [In reply to] Can't Post

Hi Fred,

It would help a lot if I could take a look at the page directly - is there any chance you could post a link to an affected page in the forum?
-----------------------------------------------------------
Cheers,
Jake Marvin - Product Specialist
support@interactivetools.com

[hr][i][url "http://www.interactivetools.com/consulting/"][b]Hire me![/b][/url]
Save time by getting our experts to help with your project. Template changes, advanced features, full integration, whatever you need. Whether you need one hour or fifty, get it done fast with [url "http://www.interactivetools.com/consulting/"][b]Priority Consulting[/b][/url].[/i]


Fredx
User

Apr 8, 2008, 2:38 PM

Post #5 of 9 (3795 views)
Shortcut
Re: [Jake] Incorrect images displayed for preview image [In reply to] Can't Post

Sure: here is the URL of the specific page:

http://www.geofftheexpert.com/listman/listings/l0024.html


ross
Staff / Moderator


Apr 9, 2008, 8:29 AM

Post #6 of 9 (3780 views)
Shortcut
Re: [Fredx] Incorrect images displayed for preview image [In reply to] Can't Post

Hi Fred

Thanks for the link!

I am beginning to think that the problem here is going to be permissions based. Basically, when you delete a listing, Listings Manager should be going into your database and removing the listing as well as going to your images folder and deleting all the images associated with that listing.

The problem, I think, is going to be that for some reason, Listings Manager wasn't able to remove the image files.

When you create a new listing, the program actually reuses your old listings numbers which have been deleted so when you go to upload images, it already things there are some there because they weren't deleted.

Could I get you to go into your images folder and just manually delete those few images for now (just the ones that start with 24_ ) and while you're there, make sure the images folder has "777" permissions if you're on a unix server or "read / write / modify / delete" permissions if you are on windows.

Let me know how you make out with that Smile.
-----------------------------------------------------------
Cheers,
Ross Fairbairn - Product Specialist
support@interactivetools.com

Hire me!  Save time by getting our experts to help with your project.
Template changes, advanced features, full integration, whatever you
need. Whether you need one hour or fifty, get it done fast with
Priority Consulting: http://www.interactivetools.com/consulting/



Fredx
User

Apr 9, 2008, 3:14 PM

Post #7 of 9 (3773 views)
Shortcut
Re: [ross] Incorrect images displayed for preview image [In reply to] Can't Post

Hi, Ross:

Perfect! I set permissions to 777. Seemed to fix the problem. The client is happy!

Fred


aerosurfer
User

Jan 12, 2009, 9:21 AM

Post #8 of 9 (2680 views)
Shortcut
Re: [Fredx] Incorrect images displayed for preview image [In reply to] Can't Post

I'm having a similar problem - the preview image does not change when I change the image in the drop down.

I'm using the template script from Ross's dynamic image gallery at http://www.interactivetools.com/forum/gforum.cgi?post=39850#39850

The line of code here is <img name="big_image" src="$listing_url$/images/$listing_num$_1.jpg">

When I replace this with the code <img name="mainPhoto" id="mainPhoto" src="$listing_url$/images/$file$" alt="" align="center"> no image appears.

Exactly what should I change this code to ?


(This post was edited by aerosurfer on Jan 12, 2009, 9:23 AM)


Donna
Staff / Moderator


Jan 14, 2009, 2:52 PM

Post #9 of 9 (2667 views)
Shortcut
Re: [aerosurfer] Incorrect images displayed for preview image [In reply to] Can't Post

Hi there,

The $file$ placeholder only works within a templatecell, it won't work on its own. There's no way to display specifically just the preview image on the listing page, as it's either generated automatically with ALL of the thumbnails, or you can specify which image you want by the order they were uploaded in.

I hope this helps. :)

Donna

--
support@interactivetools.com