/    Sign up×
Community /Pin to ProfileBookmark

Web Gallery (easy to upload new galleries)

Hello,
I’m trying to create a web gallery which would be very easy to create new galleries.
I want to do something like that:

I create a catalog – “sample”
I copy a text file there – title.txt that cantains a name of gallery – “My pictures”
I copy pictures there (via FTP client) – 1.jpg 2.jpg 3.jpg (3 pict or even 300, whatever)
Now I load some page with a PHP script that creates such page (creates index.php in a “sample” catalog):

[code=html]<html>
<head>
<meta http-equiv=’Content-Type’ content=’text/html; charset=UTF-8′>
<title>My pictures</title>
<link rel=’stylesheet’ href=’../style.css’ type=’text/css’>
</head>
<body bgcolor=’#FFFFFF’ text=’#000000′>
<span class=’textbg’>My pictures</span><br>
<p class=’desc’><p><span class=’textreg’>Click on a picture to enlarge.</span><br>
<hr size=’1′>
<a href=’content/pictures/<?php echo $picture; ?>/1.jpg’ width=’154′ height=’106′ class=’highslide’ onclick=’return hs.expand(this)’><img src=’content/pictures/<?php echo $picture; ?>/thumbnails/1.jpg’ border=’0′ class=’immg_in’ alt=’Highslide JS’ title=’Click to enlarge’ /></a>
<a href=’content/pictures/<?php echo $picture; ?>/2.jpg’ width=’154′ height=’106′ class=’highslide’ onclick=’return hs.expand(this)’><img src=’content/pictures/<?php echo $picture; ?>/thumbnails/2.jpg’ border=’0′ class=’immg_in’ alt=’Highslide JS’ title=’Click to enlarge’ /></a>
<a href=’content/pictures/<?php echo $picture; ?>/3.jpg’ width=’154′ height=’106′ class=’highslide’ onclick=’return hs.expand(this)’><img src=’content/pictures/<?php echo $picture; ?>/thumbnails/3.jpg’ border=’0′ class=’immg_in’ alt=’Highslide JS’ title=’Click to enlarge’ /></a>
</body>
</html>[/code]

[I]I don’t speak english well.. so if something’s not clear just ask ;D[/I]

to post a comment
PHP

0Be the first to comment 😎

×

Success!

Help @hryniak94 spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 6.16,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @nearjob,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,
)...