Jump to content


Photo

big help needed-possibly someone to write some php code.


  • Please log in to reply
6 replies to this topic

#1 Pudgemeister

Pudgemeister
  • Members
  • PipPipPip
  • Advanced Member
  • 94 posts
  • LocationCornwall, England, UK,

Posted 12 July 2006 - 11:53 AM

im trying to make a "ten newest videos" page on my site that looks at my videos folder and detects which videos are the newest to have arrived in the folder and then display the links or wahetever on the "ten newest videos" page.

i have looked over different sites but being a noob to all this i dont have a clue.

I don't suppose someone can possibly help or even write a script for me?

i would then b able to learn from it hoefully and help myself more in the future.

thanx

Pudgemeister
[div align="center"][a href="http://imageshack.us" target="_blank"][/a]
[/div]

#2 brown2005

brown2005
  • Members
  • PipPipPip
  • Advanced Member
  • 943 posts

Posted 12 July 2006 - 11:55 AM

do u not have a database to run with this site as it would be much easier.....

#3 Kris

Kris
  • Staff Alumni
  • Advanced Member
  • 2,755 posts
  • LocationThe Internet

Posted 12 July 2006 - 12:00 PM

If you want someone to write this for you, let me or another mod know and your post will be moved to our freelancing forum. If you want to give it a go yourself, you could look up the following functions in the manual:

glob() - To get the conents of a directory, loop through the output with a foreach() loop.
filemtime() - To get the time/date that the file was last modified on.

You can chuck all of the returned data into an array, sort it by the date/time and only use the first 10 keys.

#4 kenrbnsn

kenrbnsn
  • Staff Alumni
  • Advanced Member
  • 8,235 posts
  • LocationHillsborough, NJ, USA

Posted 12 July 2006 - 12:01 PM

If you're looking for someone to write the script, please post in the Freelancer's Forum.

Ken

#5 Pudgemeister

Pudgemeister
  • Members
  • PipPipPip
  • Advanced Member
  • 94 posts
  • LocationCornwall, England, UK,

Posted 13 July 2006 - 03:37 PM

yeh hi again all-sorry it took me a while to reply-i have alot on.

ummm yes the freelancing forum would be good-i will post in there.

i do have a database.

and those functions u sent to me are helpful thank you-but i am too much of a noob to work out how to fully use them :S

thanx all

Pudgemeister
[div align="center"][a href="http://imageshack.us" target="_blank"][/a]
[/div]

#6 pixy

pixy
  • Members
  • PipPipPip
  • Advanced Member
  • 295 posts

Posted 13 July 2006 - 04:18 PM

^ Check the PHP manual. You can download it at php.net and it has examples, how to use it, syntax, and user comments for ways they've used it. Very useful.

This is a .44 Caliber Loveletter straight through my heart.

Tabulas + Threadless + Hire Me!


#7 Pudgemeister

Pudgemeister
  • Members
  • PipPipPip
  • Advanced Member
  • 94 posts
  • LocationCornwall, England, UK,

Posted 14 July 2006 - 08:50 AM

OOOOH thank you! this will help me alot!
[div align="center"][a href="http://imageshack.us" target="_blank"][/a]
[/div]




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users