Special characters in property name of object
echo $myobject->{'%myproperty'};
Use special characters in object property name
by using variables variable as follows :
print_r($xml->{"reservation-details"});
consider the following example:
$ar = json_decode('{"var": "message", "var-1": "yello"}');
print_r($ar->{"var-1"});
Output : yello
live demo https://3v4l.org/ICTGZ
Special characters in property name
You can make class objects from json using following references
http://json2csharp.com/
Just paste your json string and it will generate C# class and properties inside that json.
Dealing with special characters in object property names
You can do that in one expression:
echo $obj->{'Revenues_(budget)'};
How to access property of javascript object with special character in property name
AngularJS does nothing special here. Refer to the regular rules for referencing properties in a javascript object.
In a controller: console.log($scope.data['Handedness;'])
In a view: {{ data['Handedness;'] }}
Object properties with special characters in EJS
Pass an object instead, then access properties on it.
res.render('index.ejs', { replace })
<%= replace['x:a'] %>
<%= replace['x:b'] %>
<%= replace['y:c.d'] %>
Related Topics
PHP - How to Create a Newline Character
Print String With a PHP Variable in It
PHP Reading Shell_Exec Live Output
How to Loop Through Two Arrays At Once
Limit Keyword on MySQL With Prepared Statement
PHP - Accessing Multidimensional Array Values
How to Get JavaScript Variable Value in PHP
Detect Bad Json Data in PHP Json_Decode()
Get Table Column Names in MySQL
Json_Encode PHP Array as Json Array Not Json Object
Sum Values of Multidimensional Array by Key Without Loop
PHP If Statement With Multiple Conditions