I heard once that this could be done using Curl, but I don't want to display all contents from an external site on my site, but only the contents from a particular div. How can this be done?
...
Hey there,
I have a database already set up. I am trying to change the collation to case sensitive on my username column so it restricts login parameters to what they signed up with.
However I keep getting this: #1025 - Error on rename of './yebutno_ybn/#sql-76dc_8581dc' to './yebutno_ybn/user' (errno: 150)
there is foreign key constr...
Hi,
let's say i have the following:
$vars="name=david&age=26&sport=soccer&birth=1984";
I want to turn this into real php variables but not everything. By example, the functions that i need :
$thename=getvar($vars,"name");
$theage=getvar($vars,"age");
$newvars=cleanup($vars,"name,age"); // Output $vars="name=david&age=26"
How can i ...
I have a very simple table on my website, that displays different URL's. I have an input field where I can type in a URL and click 'Submit' to add additional URL's.
However, I want to add an MD5 grabbing feature to this, using @md5_file(); to grab the MD5 of the URL and check to make sure it's the MD5 it should be, before adding it to ...
I want my website to automatically post status updates to a particular twitter account using OAuth in PHP.
I test this using a URL
www.mysite.com/update_status
but it asks me for "user name" and "password", which is fine when I am testing it. But my website will not be able to insert this user name and password before posting the stat...
Here is the request and response headers
http://www.example.com/get/pdf
GET /~get/pdf HTTP/1.1
Host: www.example.com
User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.2.3) Gecko/20100401 Firefox/3.6.3
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
Accept-Language: en-us,en;q=0.5
Accept-E...
I'm using Web Services to run some reports created in iReport on JasperServer. Inside the .jrxml file I can see the xml that holds the SQL for the report. Is it possible to pass this querystring over to JasperServer via Web Services, instead of hard coding the definition inside the .jrxml file. This is the string I would build in PHP...
So I'm using the following:
$r = new Record();
$r->select('ip, count(*) as ipcount');
$r->group_by('ip');
$r->order_by('ipcount', 'desc');
$r->limit(5);
$r->get();
foreach($r->all as $record)
{
echo($record->ip." ");
echo($record->ipcount." <br />");
}
Standard:
SELECT `ip`, count...
Hey quick question, I am wondering
Do big sites use php's getenv function to prevent proxy users from registering or signing in?
Is it effective in deterring hackers from creating a bunch of accounts for abusive purposes if it is used?
...
I am planning on creating my database table for users of an offline site that use as a kiosk.. Those kiosk are not connected on a network nor to each other, they have a separate webserver and database.. what Is the best thing that I can use to have these users on every kiosk to have their different unique id? I am planning using hash so ...
I have thousands of photos on my site (each with a numeric PhotoID) and I have EXIF data (photos can have different EXIF tags as well).
I want to be able to store the data effectively and search it.
Some photos have more EXIF data than others, some have the same, so on..
Basically, I want to be able to query say 'Select all photos th...
I'm trying to delete two tables rows from two different tables at once when a user clicks the delete button, but for some reason I cant get the table rows to delete can some one help me figure out what is wrong with my script? Thanks
Here is the MySQL tables.
CREATE TABLE cases (
id INT UNSIGNED NOT NULL AUTO_INCREMENT,
file VARCHAR(25...
I have this small script:
<?
header('Content-Type: text/javascript; charset=utf-8');
$s="L\u00e1szl\u00f3 M\u00e1rton";
echo $s;
?>
The browser displays "L\u00e1szl\u00f3 M\u00e1rton"
and it should display László Márton.
What I am doing wrong?
...
I am working on windows. I am running PHP (5.1.3) scripts on Tomcat using PHP/Java bridge. Here is my simple code
//test.php
<?php
require_once("java\Java.inc");
$systemInfo = new Java("Test");
print $systemInfo->foo();
?>
//test.java
class Test
{
public void foo()
{
System.out.println("hello php");
}
}
Test.class is in the same...
I get back a JSON response from a social networks site. There are certain accented characters that I would like to be removed.
An example is : L\u00e1szl\u00f3 M\u00e1rton, that reads "László Márton" and I would like to be transformed into Laszlo Marton.
I would like to keep the JSON format intact, as I will send it towards.
How can I...
EDIT: posted head code
EDIT 2: clarification on php
I have been designing a site for weeks using JQuery. I don't have a local server or a testing server so I just created a directory through FTP, '/testing'. Everything was working great in the testing directory.
I attempted to go live tonight by moving all the files in '/testing' to ...
can't make player play video served by php's readfile
...
This is my code:
<?php
$data = <<<EOL
<?xml version="1.0"?>
<!DOCTYPE html PUBLIC
"-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
<script type="text/javascript">
//<![CDATA[
var a = 123; // JS code
//]]>
</script>
</html>
EOL;
$dom = new DOMDocument();
$dom-...
Not quite sure how to ask this :)
But what I need is to have some forms online that people can fill out, like registration form etc. They will then submit it and be emailed it as well as me and have it stored in a database. Is there a way for the files to be PDFs? Can I have an editable PDF form online?
Thank you.
...
I'm trying to learn Drupal 6. I want to register the path '/topic' to a MENU_CALLBACK using hook_menu(). Here's what I have:
function mymodule_menu() {
$items = array()
$items['foo'] = array(
'page callback' => 'show_page_foo',
'access callback' => 'user_access',
'access arguements' => array('access foo con...