Jump to content

Need help with XML data to populate tables...


DeyBwah

Recommended Posts

Hey everyone.

 

I have some experience with PHP and can easily modify existing code, but seem to have trouble writing the logic from scratch.

 

Situation:

 

I'm using this Jquery slider ( http://mine.tuxfamily.org/?p=74#more-74 ) and would like to populate the slides with data coming from an XML file. The data will be text, images(URIs), and links to buy. The thing is, each slide will hold 4 items, and then I want to somehow using PHP logic, allow the code to generate the next slide...

 

In other words, how would I code it so that after 4 entries, it creates a new slide?

 

I'm imagining a For loop + SimpleXML functions... but just kind of fumbling in the dark here.

 

Any direction or guidance is greatly appreciated!

 

Kind regards,

Dey

Is your problem how to layout the XML file? Does the jQuery plugin read raw XML or JavaScript objects/arrays?

 

To make it create an extra slide if items > 4 that's something you have to write in jQuery.

 

I know how to layout the XML file.

 

The problem begins right after that. :)

 

The jQuery script that I'm using doesn't have any XML reading functionality. It was built to be hard coded.

 

I was picturing that some PHP functions/code would allow me to basically create the logic to print out my the HTML/jQuery code and populate the slides. Are you saying I need to do this in jQuery? I hope not, I'm even less versed in jQuery/JavaScript. :/

 

Please, say it ain't so!

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.