PDA

View Full Version : Controlling the initial image displayed


opeth_pp
06-17-2007, 04:23 PM
Hi Everyone..

I have what I would think should be an easy question but I can't seem to get it to work the way I want.

I am trying to control which image is displayed on the initial page a user sees. Going through the code of image_template.html I see this line


<a href="index.php?showimage=<IMAGE_PREVIOUS_ID>">


The <IMAGE_PREVIOUS_ID> tag loads the last image so I thought no problem Ill just get rid of that tag and use the specific image ID in that line and that should make the default image the one i want.


<a href="index.php?showimage=11">


This approach is not working as it is still not letting me control the first image a user sees. After making the above changes I made sure to clear my cache and test this out from a few different machines..

Any suggestions?

Dkozikowski
06-17-2007, 05:27 PM
All you did above was change the link, not the image.

opeth_pp
06-17-2007, 10:10 PM
So how would I force it to use a specific ID then or image?

I dont see a tag where I could specify such a value.

Dkozikowski
06-17-2007, 10:51 PM
Technically, you can not do this with Pixelpost. It's not meant to be used in this way.

Pixelpost uses a tag called <IMAGE_NAME> within your template. This tag dynamically changes the image name to match the current id number.

If you were to remove this tag and hard code your image file in it's place, all your pages would contain the same image.

The only feasible way i see this getting done is with a .htaccess file.

You could create a rule that would point to a specific image id each time someone visited your Pixelpost photo blog.

opeth_pp
06-17-2007, 11:02 PM
Ok thanks..
I guess another solution would be deleting images until I get the one I want loaded?

Then reload the other images.

Dkozikowski
06-17-2007, 11:36 PM
The last image uploaded will be the first image displayed.


May I ask why you want a specific image to appear first?

opeth_pp
06-18-2007, 01:14 AM
I have a specific image that a few people have said they really like and I wanted that to be the first viewed.

GeoS
06-18-2007, 06:16 AM
So there can be one more solution:
1) copy content of page which you like to make first one (default)
2) put it into index.html
3) check if static index.html is always loaded before index.php in the same dir

It can be it :)