Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   Website Design/Showcase (http://www.chiefdelphi.com/forums/forumdisplay.php?f=64)
-   -   PHP Help (http://www.chiefdelphi.com/forums/showthread.php?t=44427)

FRANK(WGH) 20-02-2006 18:29

PHP Help
 
Well this seemed to work in years past so here I am again to ask the community for some php help.
I'm working on an image gallery called <a href="http://www.solitude.dk/gallerythingie/">"Gallery Thingie"</a> which is actually a very good php gallery that relies on flat-file databases for its information. The problem i'm having is that i need to limit the amount of thumbnails that appear on a single page. I asked the creator of the script have gotten no good advice accept to look for loop tutorials.
Here's what i have have:
PHP Code:

<?php displayList($phpfile"thumbnail");?>

I'm supposed to hack this line of code to do what I want.

Any ideas anyone????

rappo 20-02-2006 22:55

Re: PHP Help
 
I downloaded the Gallery Thingie file and noticed that in the gt-pub.php there are several for loops.

Example:

Code:

function displayList($phpfile, $linktitle = "number") {
                global $name, $id, $category, $cat, $title, $path;
                for ($i=0;$i<count($name);$i++) {

You can replace the count with the amount that you want to be displayed, but that would mean that you have to implement a page function...

FRANK(WGH) 20-02-2006 23:10

Re: PHP Help
 
Quote:

Originally Posted by rappo
I downloaded the Gallery Thingie file and noticed that in the gt-pub.php there are several for loops.

Example:

Code:

function displayList($phpfile, $linktitle = "number") {
                global $name, $id, $category, $cat, $title, $path;
                for ($i=0;$i<count($name);$i++) {

You can replace the count with the amount that you want to be displayed, but that would mean that you have to implement a page function...

would you or anyone else be able to help me do something like this???

Knippschild 22-02-2006 21:49

Re: PHP Help
 
Coming from a web-developer, I suggest that you start using mySQL or some kind of database structure. Databases ensure greater stability, speeds, and security than flat-file systems offer. I know this does not exactly help your situation, but just a word of advice.

:)

Chriszuma 22-02-2006 21:51

Re: PHP Help
 
An indespensible tool for PHP development is http://www.php.net. You can look up any function in the search box for its syntax, or browse through functions by category.

Knippschild 22-02-2006 22:06

Re: PHP Help
 
Quote:

Originally Posted by Chriszuma
An indespensible tool for PHP development is http://www.php.net. You can look up any function in the search box for its syntax, or browse through functions by category.

Quite so. PHP dot net will probably become your new bible, I often use it to look up the syntax of confusing functions.. also, I always forget the parameter values for date(); :-p


All times are GMT -5. The time now is 16:35.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi