I'm wanting to build an app that lets you input your name/date of birth/location, and searches the web for public data of others who have something in common with you. The idea is to then create an infographic with this data, i.e. Average Age of John Smith: 48
Any suggestions as to what api's/techniques I could use to do this?
...
How can I explode the following string:
Lorem ipsum "dolor sit amet" consectetur "adipiscing elit" dolor
into
array("Lorem", "ipsum", "dolor sit amet", "consectetur", "adipiscing elit", "dolor")
So that the text in quotation is treated as a single word.
Here's what I have for now:
$mytext = "Lorem ipsum %22dolor sit amet%22 consect...
I'm new to codeigniter framework. Trying to get over the framework's learning curve. I've followed the nice video tutorial by codeigniter and understood the basics.
Currently, I am looking for open source projects written using codeigniter so I can read some real world production code.
A good one I found so far is bambooinvoice. Any...
Hello,
I am trying to pass multiple variables in a URL in PHP to GET some info, but I don't think it's working.
$allowedFunctions = array(
'returnAllProducts',
'refreshCurrentProduct'
);
$IDNUM = $_GET[ 'idNum' ];
$functionName = $_GET[ 'func' ];
if( in_array( $functionName, $allowedFunctions ) && function_exists( $function...
My backend accepts comma delimited id values "11,12,13". On the front end I have a check list that allows multiple selection and posts the following.
someurl.com?id=11&id=12&id=13
How do I use $_GET for multiple instances of ID, format it into a comma seperated string? Or alternatively, is there a better way to force checklists to subm...
Ok. So I am working on a website using CI. Here is the structure of my controller:
class MY_Controller extends Controller
class User extends MY_Controller
class User_Model
So, I load the User_Model inside the constructor of the User controller. I know that it is loaded properly because I tried to print something from User_Model and it ...
In some obscure situations a regular expression like "/^match/" works in the exact oposite way matching a line that is "something else", and the only way to fix it is to put the whole regex inside braces ... "/^(match)/", why is that happening?
...
I am building a back-end management application for an architect company, and they work with DWG files.
I am looking for a library that can convert DWG into any image format, preferably in PHP, but I am open to finding a work around in another language and connecting to what I've built so far.
...
At work, I'm working on including UPS integration for our product's shopping cart. I'm currently using the documented API, which supplies WSDLs. To use this API, you need a username, password and API key (our customers who use the cart for their business will have to provide this information).
There is another (undocumented) API for cal...
I need to do this for a theme:
remove_action( 'wp_head', 'rel_canonical' );
BUT I need to do that with conditional tags. The code below don't work.
if(is_page('comment'))
{
remove_action( 'wp_head', 'rel_canonical' );
}
AND I need to do this with a plugin.
I tried to hook the if statement into the function test, like this:
add...
Here is my code
<form method="post">
<input name="hash" type="text" id="hash" style='width: 30%;'/>
<input name="Crack!" type="submit" value="Crack!" onfocus="if(this.blur)this.blur()"/>
</form>
<?php
if(isset($_POST['Crack!'])){
$hash = $_POST['hash'];
$xml = simplexml_load_file("http://gdataonline.com/q...
I am building a website that remembers the users choices from a navigation menu and then shows content the next time they visit the webiste there last view content is available, to this I am running this query
SELECT * FROM (`categoryTable`)
LEFT JOIN `userMenuTable`
ON `userMenuTable`.`categoryId` = `categoryTable`.`categ...
I am making a classifieds website...
I have these 6 tables:
Every category has sub-categories (or options) which you can see below.
Lets say the user wants to post a classified, and has entered all info into the forms necessary, and I am at the stage where I have to create the PHP code to actually INSERT the data into the database.
I a...
Hi there
I'm developing a web-application using PHP which is on tests by some of my friends. What approach do you recommend me to use in order to know what warnings are they getting but without displaying them using ini_set('display_errors', 1); ?
Also, the application will run in a intranet in which I'll not have access remotely.
I w...
Hi,
limitation of tags in a wysiwyg editor by excluding buttons is completly not enough, because i still can copy a page content and past it in the editor, and... it's will accept it !
i want some solution to limit the allowed tags, by example i love the way stackoverflow limit it by the traditional way of * and quotes, but i don't wan...
how do you declare a class property as a object?
i tried:
public $objectname = new $Object();
but it didnt work.
and why should you do it like this that?
isn't it better to just instantiate that object and just use its members?
...
I have a simple text area in a form like so:
<textarea style="width:350px; height:80px;" cols="42" rows="5" name="sitelink">
<?php if($siteLink_val) echo $siteLink_val;?>
</textarea>
I keep getting extra white space in this text area. When I tab into it my cursor is like in the middle of the textar...
Ok, i have a simple .htaccess for my engine. It simply rewrites all requests to index.php (much like Wordpress does).
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
Now, i've run into an issue. I have search.php, which should be included with index.php. But, when i try to open exam...
Hi there
My application generates some .xls files and until now I was using PHPExcel lib. One of the SO has recommend me to use this approach. The problem is that I have to use some .xls templates and to append some data to them.
Who can help me with some pointers. I don't get how xlsBOF() and xlsEOF() works or have to work in my case....
how do i check if a variable is of a type mysqli object?
...