View Full Version : i'm familiar with php but i'm still confusing with this strange character ....
smansakra
02-03-2009, 03:22 AM
hello....
can anyone here tell me about these...
actually i'm falimiar with php but below character is still strange for me.
@getMemberThumnail($name) --> why does it use "@" before function?
what is RMS?
what is RSS?
thanks.... :confused:
Good question.
The @ symbol checks for errors (will return true if it finds errors, otherwise false). For example:
mysql_connect('localhost', 'root', '');
if(@mysql_connect('localhost', 'root', '')){
die("Error!");
}
This will check to see if there are any errors in connecting to the database, if there are die Error!.
RMS - Root Mean Square. (http://en.wikipedia.org/wiki/Root_mean_square)
Schmoopy
02-03-2009, 03:29 AM
The @ sign means that no error messages will be printed if the getMemberThumbnail does not succeed.
RSS - Rich Site Summary RSS Definition (http://dictionary.reference.com/browse/Rich%20Site%20Summary)
Not sure about RMS though.
smansakra
02-03-2009, 03:40 AM
hum? :: thinking::
so does anyone here know about "RMS"?, i work with dolphin software from boonex.com , ti uses rms on it.
what is it and what is it used for?
I think it may be something dolphin software made up. When I search RMS 3.5.1 on google (http://www.google.com/search?hl=en&rlz=1C1GGLS_en-USUS301US308&q=RMS+3.5.1&btnG=Search) I get this.
Dolphin 6.1.1 & RMS 3.5.1 :: hd4real's blog
So, I think I finally have RMS 3.5.1 working on my server. My only problem now is that my Ray widgets do not load. This happens with Adfree & Free 6.1.1 ...
www.boonex.com/unity/blog/entry/Dolphin_6_1_1_RMS_3_5_1 - 51k - Cached - Similar pages -
smansakra
02-03-2009, 04:12 AM
so , do you think that RMS is dolphin's own modules?
if it so, just boonex.com that know what is it and what is it used for on my dolphin.
Well, not just boonex.com. But I do think it is just dolphin's.
Although - I don't really know.
JasonDFR
02-03-2009, 07:32 AM
Good question.
The @ symbol checks for errors (will return true if it finds errors, otherwise false). For example:
mysql_connect('localhost', 'root', '');
if(@mysql_connect('localhost', 'root', '')){
die("Error!");
}
This will check to see if there are any errors in connecting to the database, if there are die Error!.
RMS - Root Mean Square. (http://en.wikipedia.org/wiki/Root_mean_square)
Nile, not exactly. The @ symbol causes errors an expression may cause to be ignored or supressed. A common use is to ignore errors the mysql_connect() function may cause because printing these errors on the screen could compromise your database security.
Check here: http://www.php.net/manual/en/language.operators.errorcontrol.php
Remember that when you are developing a site you want to see ALL errors your code produces, but when the site is live you don't want to display errors to the users. Especially errors that could compromise your sites security. You have to figure out an elegant way of handling errors on your live site. For example, depending on what kind of error occurs, you could just ignore it, display a "Sorry" message to the user, and / or have error information emailed to you or logged somewhere.
As everyone knows, RMS is Richard Matthew Stallman (http://en.wikipedia.org/wiki/Richard_Matthew_Stallman).
Schmoopy
02-03-2009, 10:31 PM
As everyone knows, RMS is Richard Matthew Stallman (http://en.wikipedia.org/wiki/Richard_Matthew_Stallman).
Is it you :p?
smansakra
02-04-2009, 06:01 AM
RMS IS USED by dolphin and ray software.
http://www.boonex.com/unity/forums/#topic/what-is-RMS--2009-02-02.htm
Er, I just noticed:
The @ symbol checks for errors (will return true if it finds errors, otherwise false).That's untrue. @ simply causes all errors to be ignored — the return value of the expression is not changed. That means that this:
mysql_connect('localhost', 'root', '');
if(@mysql_connect('localhost', 'root', '')){
die("Error!");
}
This will check to see if there are any errors in connecting to the database, if there are die Error!.is untrue: in fact it's completely backwards. If the connection succeeds the value of mysql_connect() is truthy, so that will die iff the call succeeds.
I said that errors were ignored, but that's not necessarily entirely true: if track_errors is enabled in the server config, the error generated by the expression will still be assigned to the global variable $php_errormsg.
smansakra
02-04-2009, 08:00 AM
so , what is it:
&$name , on this function--> getNickName(&$p);
and what is it :
$$name
?????
JasonDFR
02-04-2009, 08:20 AM
I don't know about the & in your example.
For the double $$:
$$name is a variable that has the name of the value of $name. Confusing huh?
If you do something like:
$name = 'jason'; // Simple variable
$$name = 'jason'; // Create a variable. Replace $name with it's value, jason, thus creating $jason = jason
echo "$jason"; // This outputs jason, even though we didn't type $jason = 'jason';
This is pretty confusing at first. And probably not something a beginner is going to use often. I've used it once for making new variables from information pulled out of a database.
And probably not something a beginner is going to use often.It's not something that anyone should use. Ever. If you find yourself using it, you're doing it wrong. Probably you would be better off with an associative array.
The & in the above example makes a reference: it means that in code, those two variables are actually two names for the same thing. Performing an operation on one is the same as performing an operation on the other. For example:
function brokenAddThree($n) {
// $n is a new copy of $m, so this modification doesn't affect $n itself.
$n += 3;
}
$m = 2;
brokenAddThree($m);
$m // 2
function workingAddThree(&$n) {
// Here, $n is the same thing as $m, so modifying it also modifies $m.
$n += 3;
}
$m = 2;
workingAddThree($m);
$m // 5Making the references explicitly at calltime, which seems to be what you were doing above, works but is deprecated:
function deprecatedAddThree(&$n) {
$n += 3;
}
$m = 2;
deprecatedAddThree(&$m); // Throws a deprecation warning
$m // 5
smansakra
02-05-2009, 04:30 AM
I don't know about the & in your example.
you don't know?
ups, you should study php again.... he he he :D
i see many of them are on dolphin and orca( boonex.com products )
hi, i agree with twey:o
gurmeet
02-05-2009, 03:27 PM
@ sign is used when we want to execute any function n ignore any error that is bring produced by this function...
for instance there is any function , when we are caling that function it gives us a warning message, by using '@' sign that warning message will be discarded...
Powered by vBulletin® Version 4.2.2 Copyright © 2021 vBulletin Solutions, Inc. All rights reserved.