I'm working on an existing code base and got back an object with an attribute that starts with a number, which I can see if I call print_r on the object.
Let's say it's $Beeblebrox->2ndhead. When I try to access it like that, I get an error:
Parse error: syntax error, unexpected T_LNUMBER, expecting T_STRING or T_VARIABLE or '{' or '$...
Any one have tutorial for new facebook apis VERSION '2.0.5'
thanx
...
I have this currently in PHP and was wondering what the equivalent would be in Java.
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $vals[$index["CM:URL"][0]]["attributes"]["VALUE"]);
header("Content-type: " . $vals[$index["CM:RESOURCEOBJECT"][0]]["attributes"]["MIMETYPE"]);
$content = curl_exec($ch);
curl_close($ch);
Thanks!
...
Why would I chose something like Interwoven Teamsite as opposed to Joomla, Django, Wordpress etc. I guess the question is how can one justify the cost associated with a teamsite license. Also by going the teamsite route, do I have any limitations on what can or cannot be modified.
Thank you
...
Hi,
I have a script that has ignore_user_abort(TRUE); at the top and I call it like this
$socket = curl_init("http://...");
curl_setopt($socket, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($socket, CURLOPT_TIMEOUT_MS, 1000);
$result = curl_exec ($socket);
curl_close($socket);
This script does some boring work that I want to run in the ba...
Hello there,
I'm writing code to recursively replace predefined variables from inside a given string. The variables are prefixed with the character '%'. Input strings that start with '^' are to be evaluated.
For instance, assuming an array of variables such as:
$vars['a'] = 'This is a string';
$vars['b'] = '123';
$vars['d'] = '%...
Hi guys, im gonna install a drupal multisite behavior: common codebase and one database per site.
The idea is to keep the modules that are used by all the sites in the /sites/all/modules/ folder, and the themes and modules used just by one sites in it /sites/example1.com/ folders.
I've read the 10 minutes multisite configuration and al...
Why all PHP Functions for (Array , String , Database etc. handling) arent True OOP Methods.
We can just call them like 'static' methods anywhere. PHP5 and PHP6 advertise themselves as True OOP Languages , but what about Encapsulation then ? I think In a proper World all Array methods should belong to Array Class and String Methods should...
I have an as3 project that lets a users create labels for jars and containers (think t-shirt editor) using custom images and text.
To send them to the printer as pngs, I create a Bitmap object and use a scale matrix and they come out perfect.
There is, however, a 2-14 sec lag between building the bitmap, sending it to the php service...
I've built a function for checking a username. I'm using it as a callback for form validation in CodeIgniter, and it works nicely. However, I'd like to also use it with AJAX to check on the fly if the user has JS enabled. So my controller has this:
function check_username($s = FALSE)
{
if ($s):
$this->db_common->like('userna...
I have a javascript file (.js file, not HTML file) containing several js functions. I want to call one of the PHP functions in a PHP file containing only several PHP function from within one of the js functions. Is that possible? Would I need to "include" the .php file containing the php function in the .js file? How would I do that?...
I work at a hospital and have developed a way to estimate the total patient financial responsibility for services, after insurance has paid it's obligation, and before any services are rendered. A lot of patients are calling for quotes, and I wanted to find a secure way to email those results to the patient at their request.
I'm conside...
I am maintaining a custom built and highly OO e-commerce application. The original designer made a few assumptions like:
- there will never be more than 3 types of sales tax (state, national & hamonized)
- each type of sales tax can have only one rate.
- each state will be assigned one of the three tax types.
He should have known b...
I'm planning on building a mySQL table that requires a student's name which looks like this:
Last Name + Father's First Name Initials + First Name
Example:
Beavers L. Scott James (father has one first name, son has two first names)
Beavers L. D. Scott (father has two first names)
Instead of requiring to fill in 3 input fields, I o...
I want to allow users to use their own stylesheets for thei profiles on my forum, but I'm afraid of possible security vulnerabilities. Does anyone have any tips for sanitizing CSS?
Basic process: User enters CSS into form -> Save to DB -> Output as inline CSS
...
Folks, I'm building a website for a very non-tech-savvy audience. The intent is to allow them to pick a website template from a list, and then customize the content of the provisioned website lightly.
The emphasis of ease of use (target audience can use email, and maybe facebook, but HTML is an acronym they've never heard, and neither ...
Hi,
Which good ways exists to reload front page by server every time that new article placed by editor in front page for (news popular website like fox.com, cnn.com)?
Thanks
...
Hi,
I own the a domain like "www.example.com". How do I setup ownership over "api.example.com"?
And I have all my files hosted on a php server (at a hosting provider) and when I login to the file system I can see stuff like:
/index.php
/help/index.php
etc.
How do I map stuff like: api.example.com/v1/getAnimalNames.php
to a file ...
By enabling Wake-on-LAN on my PC, I can remotely power it on.
Suppose I want to send the "magic packet" from a PHP script. How would I do this? Would I need to use the cURL functions?
...
I cannot render an excel file for download correctly using SSRS SDK for PHP. I can for a CSV, and I can render one for PDF inline. The contents of produced file is garbage when viewed in EXCEL. Here is my code:
$renderAs = new RenderAsEXCEL();
$result = $ssrs_report->Render2($renderAs,
PageCountModeEnum::$Estimate,
...