WARNING: I am watching u!
Coding forum FAQ + Bookmarked threads
Following are a few bookmarked links to the most common questions on this forum.
- How to avoid PHP handling errors : generated by the functions, Why is the @ symbol used?, What is the difference between functionname() and @functionname().
- Resizing Images
- Pagination (alternative, alternative 2): Span pages like - Page 1, Page 2, Page 3, .... or 1-10, 11-20, 21-30, ...
- Alternating Row Colors : How to have alternating row colors in a table
- Clickable Ordering : Sorting the rows in Ascending or Descending order by any field just thru a single click.
- Register Globals : Let the script behave as if register_globals is on even if it is off.
- Writing numbers with decimal places, e.g., 4.5 as 4.50; it's called number_format, people.
- My variables don't work when I 'write $them like this'. No, they don't. If you want variables inside strings to work like variables the strings need to be "double-quoted". Info can be found here, here, here, here, and most importantly here.
- A parse error about some kind of "unexpected $end" on the very last line of the file? You're probably missing a closing brace. If you're not (have you checked?), that thread suggests some other possibilities. But a missing "}" is the most likely cause.
- GD Lib is messing up the colours of my images!
- cron: It's for running programs at regular intervals. You can use it for your scripts, too. (Windows has a task scheduler.)
- Bunkermaster's Debugging 101 thread in the Echo Lounge.
- planetsim's sister thread to this one.
- planetsim has also compiled a list of tutorial links.
- PHP Manual
- www.php.net/links. Professional associations, link catalogues, FAQs, script libraries, developers' articles, tutorials, magazines, accelerators/encoders/compilers, editors, hosting, job listings.... you still here?
- Paul Hudson's Practical PHP Programming
If you feel that we missed out some. Just PM moderators of this forum.
All replies to this thread when this thread is unlocked/being edited will be deleted.
When you have got your problem solved please click the "Mark Thread Resolved" at the bottom of the thread. This makes it easier for people go to threads where there are more chances of them finding a working solution.
Extra board markup
- For posting PHP code, put it in [php]...[/php] tags:
for($i=$n+50; $i<2*$n; $i++)
echo "Just some text on line $i\n";
- For HTML markup, use [html]...[/html] tags:
<form action="upl.php" method="GET">
<input type="text" value="FOO!" /> and then <input type="submit" value="SUBMIT!" />
- For any other sort of code and stuff for which you want the spacing to remain
unchanged, use [code]...[/code] tags:
id | username | passwd
1 | jsmith |cae8d14edd025e72c59dbab6f378c95a
2 | ffoobar |6cfe61694ee1bb13ae719d47c2f80b7a
3 | jbloggs |8fc42c6ddf9966db3b09e84365034357
4 | hseldon |e82df739dd8c84c8ae105b514f4c10df
5 | dolivaw |0e9312087f58f367d001ec9bae8f325a
|| | \
- To prevent vBulletin from parsing board markup tags when you don't want it to, wrap them in [noparse] ... [/noparse] tags. This works for smilies, too :).
- Please use these, as they make code much easier to read!
Do's / Don'ts
- The General overview:
If it's improper to say something in a public place comprised of mixed races and ages, it's inappropriate to post it here in the forums.
- Advertising on the board:
We can't allow this in any form. If someone is interested in getting exposure through the site, please contact the administrator via email at firstname.lastname@example.org . Footers may contain a pitch - it's a bit of a trade-off. The user is contributing to the community and in return they get exposure via their footer. Posting useless stuff and a huge ad in their footers is a complete NO.
- Off topic posts:
Please use the Echo Lounge forum.
- Footer size: We need to limit this to 5 lines. Obviously if there are 20 posts on a page and we allow more, we'll end up with 100 extra lines to scroll when reading messages.
- Job posts:
They all go here. Posting them anywhere else will see them deleted, and may earn an infraction.
Last edited by Weedpacket; 10-27-2011 at 08:07 PM.
WARNING: I am watching u!
Keep sending suggestions folks!!!
Missing in Action
You could throw some links up there to the MySQL manual and MySQL reserved words page
Yeah...I should probably provide the links...[/edit]
Last edited by LordShryku; 11-01-2003 at 01:29 AM.
wondering about the '&' sign? check this post out.
Hi...i'm new at this PHP thing and i'm not sure how to code things and how the code thing works....where do the codes go? i'm an administrator on a website...where am I supposed to put the codes? I'd greatly appreciate it if you can help me out..
Codes start with either <?php or <? depending upon your PHP setup. The first is the global way, the second is an alternative (called "short tags") and isn't guaranteed to be enabled on every server.
The ending tag is ?> (note no PHP) and delimits that the PHP parser should stop parsing at that point.
You can chunk code like:
and the parser would do all the code.
// This is the first chunk
<!-- Some HTML code would be in here -->
/// This is the second chunk
With PHP, each line is ended with a semicolon (. If you don't end your line with it, you get a parse error, then you have to go find where you missed it.
You can of course read all this and more in the manual (linked above).
and maybe start from this page:
rather than start a whole new thread, whats the usage of the arrow for? $var->something;
***If your problem has been solved, PLEASE click the RESOLVED LINK
under "Thread Tools"***
Apache 2.4.x | PHP 5.4.x | MySQL 5.x
| Learn HTML
| Validate HTML
$var is an object in PHP and the arrow "->" is something like the function/child of that object.
I registered but none of my posts will appear
Last edited by willg; 11-13-2007 at 01:11 PM.
Yes, possibly because your posts are moderated for whatever reason (content, links, whatever) and is waiting on a Mod to approve your posts. I've approved your posts. Next time, if your post doesn't show up immediately, you don't need to repost, just wait for a few hours. If it still doesn't show up, just wait longer.
Also use latest php
We should also put out a message telling users to move to PHP5.
Or have a message to all developers as "Recommended to use PHP 5.2 or later"
We had just such a notice posted throughout the second half of last year.
Originally Posted by php-web
PHP 4 IS NO LONGER BEING SUPPORTED!!
UPGRADE PHP AS SOON AS POSSIBLE.
PHP has announced that PHP 4 will no longer be supported beginning January 1, 2008. They ask people to start migrating over to PHP 5 now.
Critical security releases for PHP 4.4 will be released on a case-by-case basis
Originally Posted by PHP
PHP 4.4.9 is the FINAL
version of PHP. According to some, the Suhosin
project will continue to release security updates for the 4.4 branch; however, PHP 4.x is no longer supported by the PHP group. Suhosin is a 3rd-party development project. It is highly recommended you upgrade.
High Energy Magic Dept.
There's even a web site dedicated just to encouraging the upgrade: GoPHP5.org
Please give us a simple answer, so that we don't have to think, because if we think, we might find answers that don't fit the way we want the world to be." ~ from Nation, by Terry Pratchett
"But the main reason that any programmer learning any new language thinks the new language is SO much better than the old one is because he’s a better programmer now!" ~ http://www.oreillynet.com/ruby/blog/...ck_to_p_1.html
Glad to see my sticky could be made useful
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Tags for this Thread