Webmaster Forum

Go Back   Webmaster Forum > Web Development > Coding Forum

Coding Forum Problems with your code? Discuss coding issues, including JavaScript, PHP & MySQL, HTML & CSS, Flash & ActionScript, and more.


Reply
 
LinkBack Thread Tools Display Modes
Old 11-04-2009, 05:17 PM   #1 (permalink)
v7n Mentor
 
abajan's Avatar
 
Join Date: 08-08-09
Location: Barbados
Posts: 119
iTrader: 0 / 0%
Latest Blog:
None

abajan is just really niceabajan is just really niceabajan is just really niceabajan is just really niceabajan is just really niceabajan is just really niceabajan is just really niceabajan is just really niceabajan is just really niceabajan is just really nice
Question Of Brackets, Braces, Parentheses, Slashes and Backslashes

To my knowledge...
Code:
these are parentheses: () these are brackets: [] these are braces: {} this is a slash: / and this is a backslash: \
Yet during my quest over the years to jam my brain silly with as much computing stuff as possible, I’ve noticed that many folk call parentheses “brackets”, brackets “square brackets”, braces “curly brackets” or occasionally “curly braces”, and slashes “forward slashes”. The only one everyone seems to agree on is the backslash.

Just out of curiosity, what do you peeps call these various symbols?
__________________
If my posts offend thee, I’m just blowing my own horn!
abajan is offline  
Add Post to del.icio.us
Reply With Quote
Old 11-04-2009, 06:01 PM   #2 (permalink)
V7N Administrator
 
Cricket's Avatar
 
Join Date: 10-13-03
Location: Texas
Posts: 23,538
iTrader: 0 / 0%
Cricket is supreme webmaster materialCricket is supreme webmaster materialCricket is supreme webmaster materialCricket is supreme webmaster materialCricket is supreme webmaster materialCricket is supreme webmaster materialCricket is supreme webmaster materialCricket is supreme webmaster materialCricket is supreme webmaster materialCricket is supreme webmaster materialCricket is supreme webmaster material
Quote:
Originally Posted by abajan View Post
To my knowledge...
Code:
these are parentheses: () these are brackets: [] these are braces: {} this is a slash: / and this is a backslash: \
Yet during my quest over the years to jam my brain silly with as much computing stuff as possible, I’ve noticed that many folk call parentheses “brackets”, brackets “square brackets”, braces “curly brackets” or occasionally “curly braces”, and slashes “forward slashes”. The only one everyone seems to agree on is the backslash.

Just out of curiosity, what do you peeps call these various symbols?
I use almost exactly the same except I specify forwardslash.
__________________
GNC Web Creations - Free Search Engine Optimization (SEO) Training Class
Website Development Training - Website Development Training Blog

What are you waiting for? Submit your site to directory.v7n.com today!
Cricket is online now  
Add Post to del.icio.us
Reply With Quote
Old 11-04-2009, 07:09 PM   #3 (permalink)
v7n Mentor
 
CyberWizard's Avatar
 
Join Date: 10-11-09
Location: Texas
Posts: 999
iTrader: 0 / 0%
Latest Blog:
None

CyberWizard is a splendid one to beholdCyberWizard is a splendid one to beholdCyberWizard is a splendid one to beholdCyberWizard is a splendid one to beholdCyberWizard is a splendid one to beholdCyberWizard is a splendid one to beholdCyberWizard is a splendid one to beholdCyberWizard is a splendid one to beholdCyberWizard is a splendid one to beholdCyberWizard is a splendid one to beholdCyberWizard is a splendid one to behold
I never called braces anything - they are too hard to describe

As far as slashes I would always specify forward or back.
__________________
LinkSqueezer :: Free URL Cloaking For Pro Marketers
Are are you a marketer or affiliate wanting to mask your links?
CyberWizard is online now  
Add Post to del.icio.us
Reply With Quote
Old 11-05-2009, 03:57 PM   #4 (permalink)
v7n Mentor
 
megamoose's Avatar
 
Join Date: 06-04-06
Location: Northern Ireland
Posts: 489
iTrader: 2 / 100%
Latest Blog:
None

megamoose is a glorious beacon of lightmegamoose is a glorious beacon of lightmegamoose is a glorious beacon of lightmegamoose is a glorious beacon of lightmegamoose is a glorious beacon of lightmegamoose is a glorious beacon of lightmegamoose is a glorious beacon of lightmegamoose is a glorious beacon of lightmegamoose is a glorious beacon of lightmegamoose is a glorious beacon of lightmegamoose is a glorious beacon of light
Send a message via ICQ to megamoose Send a message via MSN to megamoose Send a message via Yahoo to megamoose Send a message via Skype™ to megamoose
I call these open and close brackers: ()
Square brackets: []
Curly Brackets: {}
Forwardslash: /
Backslash: \

Suppose it doesn't really matter what they're called and TBH I very rarely feel the need to describe them
__________________
Message me for PHP | HTML | CSS | JAVASCRIPT | .NET | MySQL help and support
megamoose is offline  
Add Post to del.icio.us
Reply With Quote
Old 11-05-2009, 05:11 PM   #5 (permalink)
Moderator
 
Join Date: 02-10-07
Location: Central Kentucky
Posts: 1,291
iTrader: 2 / 100%
Latest Blog:
None

ScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest order
To be really honest, it depends on which one I omitted and how long it took me to find it.

On a good day I agree with you.

The missing brace can take the longest. Hence the more colorful names are reserved for it.

I have that missing semi-colon down pat. It is one line above the error code.
__________________
These forums are as good as the posts that you contribute to them.
~~
ScriptMan
Webmaster Help Articles
Domains & Sites For Sale by Owner
ScriptMan is offline  
Add Post to del.icio.us
Reply With Quote
Old 11-05-2009, 05:41 PM   #6 (permalink)
v7n Mentor
 
abajan's Avatar
 
Join Date: 08-08-09
Location: Barbados
Posts: 119
iTrader: 0 / 0%
Latest Blog:
None

abajan is just really niceabajan is just really niceabajan is just really niceabajan is just really niceabajan is just really niceabajan is just really niceabajan is just really niceabajan is just really niceabajan is just really niceabajan is just really nice
Quote:
Originally Posted by ScriptMan View Post
To be really honest, it depends on which one I omitted and how long it took me to find it.

On a good day I agree with you.

The missing brace can take the longest. Hence the more colorful names are reserved for it.

I have that missing semi-colon down pat. It is one line above the error code.
Now that you mention it, last night I stumbled upon what appears to be a nifty online tool but I’m yet to try it out. (Presently, my code blocks are pretty small and Notepad++’s highlighting features suffice for the time being but others might find BalanceBraces to be useful.)

BTW, thanks for the semicolon tip.
__________________
If my posts offend thee, I’m just blowing my own horn!
abajan is offline  
Add Post to del.icio.us
Reply With Quote
Old 11-06-2009, 06:42 AM   #7 (permalink)
Moderator
 
Join Date: 02-10-07
Location: Central Kentucky
Posts: 1,291
iTrader: 2 / 100%
Latest Blog:
None

ScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest orderScriptMan is a web professional of the highest order
When building nested conditionals where there may be a series of braces I usually test each fragment to make sure it is doing what I want and then tag them as shown below as I construct the script.

Quote:
if (something isset)
{ // open isset
if a condition
{ // open 1
action line of code
} //close 1

if a condition
{ // open 2
action line of code
} // close 2

} // close isset
In this simple example that seems unnecessary but if you throw in a couple of whiles and elses you start to see the need.

I also frequently have debug routines which are simple echo statements to test the input or post functions.

Quote:
error_reporting(E_ALL); // debug only
include ("config.php");

/*
echo "The following lines are part of the debug routine.";
echo "<br>";
echo $_POST['date'];
echo "<br>";
echo $_POST['title'];
echo "<br>";
echo $_POST['desc'];
echo "<br>";

*/
That link you posted looks interesting
__________________
These forums are as good as the posts that you contribute to them.
~~
ScriptMan
Webmaster Help Articles
Domains & Sites For Sale by Owner
ScriptMan is offline  
Add Post to del.icio.us
Reply With Quote
Go Back   Webmaster Forum > Web Development > Coding Forum

Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Yahoo slashes 10% of workforce Natural Elements SEO Forum 9 10-24-2008 05:42 AM
Strange request with 3 slashes in URL thing2b Coding Forum 4 01-31-2007 01:56 AM
Using Brackets in PHP al2six Coding Forum 7 11-28-2006 09:36 PM


Sponsor Links
Get exposure! Contextual Links V7N SEO Blog V7N Directory


All times are GMT -7. The time now is 01:36 AM.
© Copyright 2008 V7 Inc
Powered by vBulletin
Copyright © 2000-2009 Jelsoft Enterprises Limited.


Search Engine Optimization by vBSEO 3.3.0 ©2009, Crawlability, Inc.