473,772 Members | 2,349 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

PHP Forum

PHP web programming language - Ask questions about php scripting, databases, mysql, templates, PEAR, php functions, PHP-GTK, setup and installation, object oriented programming, classes, files, security, sessions, arrays and more.
10
2,422
thread by: smorrey | last post Oct 16 '05 by: Drazen Gemic
Hello all, I am writing an app in PHP that uses a PostGres database. One thing i have noticed is that what should/could be a single line of SQL code takes about 6 lines of PHP. This seem wasteful and redundant to me. Here is a sample of what I'm talking about ($db is a PDO already defined and created).
5
2,092
thread by: specjal | last post Oct 16 '05 by: Janwillem Borleffs
hi in form TEXTAREA i have text like: bla bla http://www.google.com/bla/bla/bla text text text text now how to make from this text like: bla bla text text text text
2
1,871
thread by: totalstranger | last post Oct 16 '05 by: totalstranger
I've looked at and installed PatUser http://www.php-tools.net/site.php?&file=/patUser/overview.xml and PHPautomembersarea http://www.dwalker.co.uk/phpautomembersarea/ but neither of those systems seem to do what I want, which is: some PHP pages need to run for anybody on the web and also for signed on users that get additional content, I...
3
6,550
thread by: Mazin07 | last post Oct 16 '05 by: scott Johnson
Let's say I have function dosomething ($var1, $var2, $var3) { ... } How do I make $var3 optional so that I can pass only 2 arguments and still have it work?
0
1,167
thread by: madsmh | last post Oct 16 '05 by: madsmh
When I try ti install DB I get this output: # pear install db downloading DB-1.7.6.tgz ... Starting to download DB-1.7.6.tgz (124,807 bytes) .............................done: 124,807 bytes requires package `PEAR' >= 1.0b1 DB: Dependencies failed When I try to install the newer PEAR I get:
4
2,510
thread by: Baptiste Pillot | last post Oct 16 '05 by: Jerry Stuckle
Hello, With php4 I did the following in class initialisation : class base_class { function modify_polymorphic($otherclass){ $this=new $otherclass(); }
5
1,712
thread by: Davide | last post Oct 16 '05 by: Davide
Hi all. With this simple script I can see all my jpg in a web page.. but they are confused randomly in the page. is there a way to put them alfabetically? from A to Z? thanx <?php if ($handle = opendir('/cover')) {
4
1,996
thread by: system7designs | last post Oct 16 '05 by: Mladen Gogala
I don't know preg's that well, can anyone tell me how to write a regular expression that will select everything BUT files/folders that begin with ._ or __?(that's period-underscore and underscore underscore)
1
2,146
thread by: JaxDawg | last post Oct 15 '05 by: Tim Roberts
Many of you recommend SlickEdit for PHP development. One thing I haven't been able to determine is if it has a debugger for PHP scripts? Looking for breakpoint, watch lists, etc. similar to what the major ide's have. Thanks!
1
292
thread by: Ian Davies | last post Oct 15 '05 by: Stefan Berglund
Hello My host does not allow external connections to my MySQL database on their server from a remote computer. I would like users of my VB application to be able to add records from a table on said database to their local MySQL database. Can anyone advise me of my options to solve this one (appart from changing host)? Thanks Ian
17
3,166
thread by: windandwaves | last post Oct 15 '05 by: juglesh
Hi Folk I am reading the info below and I am thinking, just how trusted is it. I have a redirection in place using an .htaccess file. The file it redirects to is 404.php. Is there a way to find out what the file was that people entered originally? I was thinking about $_SERVER but that does not seem to do the trick (it is empty). ...
2
24,004
thread by: joes | last post Oct 15 '05 by: joes
Hi folks! I noticed in my static example which I did in PHP that the static variable is not stored over multiple php pages. So this does differ than to other OO languages like JSP. Is this so or did I something wrong? MyClass.php: <? class MyClass
3
3,345
thread by: alex | last post Oct 15 '05 by: alex
Hi, I'd like to globalize my website. I've seen some pre-coded php apps using this kind of code : echo __('Hello') ; This displays the Hello message in the correct language. I can't get how it works and no doc over the web about that !
4
1,756
thread by: Dave Moore | last post Oct 15 '05 by: Christopher Pomasl
Hi All, I'm putting a website together using PHP and a MySQL database. I've been using phpMyAdmin as it makes updating the DB nice and easy. For development, I've been using Apache, MySQL and PHP installed on my local machine but now I'm having problems porting to my hoster's server. To transfer the database contents, I've exported the...
5
2,099
thread by: IWT | last post Oct 15 '05 by: Toby Inkster
Ive heard about some sort of script or program that converts a web address with a php extension to that with a html. E.g. say if you had www.abc.com/123.php the user would be able to access this via www.abc.com/123.html. We're creating a new site in php and dont want to effect our search engine rankings by getting rid of all our existing html...
1
25,132
thread by: bissatch | last post Oct 15 '05 by: Chris Hope
Hi, I use MySQL databases for my websites but at work I use PostgreSQL databases. Is there such a thing, similar to PHPMyAdmin, for PostgreSQL where I can view table structure, browse table data, run sql queries, backup etc? Cheers Burnsy
7
3,383
thread by: ralphNOSPAM | last post Oct 15 '05 by: R. Rajesh Jeba Anbiah
Is there a PHP script that can find unused variables? I'd like to 'clean up' my scripts. Thanks...
1
1,379
thread by: Hemanth | last post Oct 15 '05 by: R. Rajesh Jeba Anbiah
Hello there, A newbie question....any help is appreciated. I'm trying to create a script that searches a few database tables based on the search text and user search preferences. I created a PHP script (search_form.php) that displays textbox, a search button and a preferences link. The preferences link opens a popup (preferences.html)...
7
1,876
thread by: DartmanX | last post Oct 14 '05 by: DartmanX
I have created a wizard which walks a user through a process of selecting data to be generated into an XML file. Each page adds its own data to $_SESSION, until the final page. On this page, an input button launches a PHP script (genHTML.php) that creates an HTML file. The genHTML file starts by setting two headers: header('Content-type:...
8
1,419
thread by: James | last post Oct 14 '05 by: Geoff Berrow
I'm just beginning my PHP studies and one of the first tutorials gives different results. The user is prompted for a Name, and PHP is to say "Welcome <name>!" on another page. On my hosted server the example works fine, but on my own machine the message "Welcome !" is displayed, instead of "Welcome James!" (or whatever). The code: ...
9
1,878
thread by: Oliver Saunders | last post Oct 14 '05 by: Ewoud Dronkert
This is an amazing opportunity to win a tin of sardines if you can answer this difficult question correctly! Question: What kind of loop do you need to turn an array like this: $notes = array( '1:1', '1:2', '1:3'
4
2,965
thread by: Marcel Brekelmans | last post Oct 14 '05 by: Justin Koivisto
Hello, I seem to get an extra empty field in every 'mysql_fetch_array' command I issue. For example: I have a simple table 'tblName': ID Name 1 Jane 2 Joe 2 Doe
4
1,378
thread by: Japhy | last post Oct 14 '05 by: Japhy
hello, I am finding that setting session variables is very unreliable (for me). Am I doing something wrong with syntax : $contnum = getrequest("ID1") ; (ID1 is passed in the URL) $_SESSION= $contnum ; My program will randomly start to fail. If I echo $sess_contnum, sometimes it is set, sometimes not.
2
1,861
thread by: comp.lang.php | last post Oct 14 '05 by: R. Rajesh Jeba Anbiah
I am simply trying to zip together selected files into a single ZIP file. Windows XP doesn't have a native process by which you can do this, so I borrowed gzip, downloaded and installed, and upon using it: <? $msg = exec('gzip -q --suffix .zip '. @join(' ', $fileArray)); ?> All of my files named in $fileArray were horribly mangled!!...
4
9,610
thread by: Marius III | last post Oct 14 '05 by: R. Rajesh Jeba Anbiah
Hi there friends, I want to encode a date in PHP5. I have 3 variables for ex: $day = 20 (integer) $month = 10 (integer) $year = 2005 (integer)

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.