Wordpress list of authors
How do I get an array or list of users in wordpress? I want to be able to store a new list of authors for permissions for a new plugin I'm working on. ...
How do I get an array or list of users in wordpress? I want to be able to store a new list of authors for permissions for a new plugin I'm working on. ...
I have a (probably not) unique issue with a css background div I am seeking advice on. I am using Wordpress, which creates my pages dynamically. The front page and some other pages are using one type of background (Gradient) while internal pages are using a solid white. Right now I am forced to have two style sheets - main.css for the gr...
I have a XML setting I am trying to load using simplexml. The XML setting can be edited by the user of a web application. I want to handle errors myself and dispatch a warning message to the user interface. However, simplexml keeps throwing warnings on malformed XML instead of quietly returning false. How can I make simpleXML shut up a...
Hi guys, What would be the best approach for the following.... Website 1 - has 300+ individual .html product pages (no database involved) The products/content from Website 1 need replicating on Website 2, Website 3, Website 4 and Website 5. Each site is location based e.g glossop-bikes.co.uk, buxton-bikes.co.uk, hyde-bikes.co.uk etc....
I have the code below that i use to download a file from the HDD. The problem I get is that if I stop a download in the middle or after the download ends, the site becomes unresponsive. Any idea why? The environment is LAMP. . . . // get mime type if ($dwld_allowed_ext[$fext] == '') { $mtype = ''; // mime type is not set, get fr...
Hi , Basically I have setup up SESSIONS on my site. Once a user registers an Auto Incremented ID is made for this user (I hope that is the right word) What I want to do is once the POST method is sent and the user is signed up on the next page say if the action is Welcome.php I would like on the Welcome.php page to echo the users ID...
php code: <?php echo json_encode(glob("photos-".$_GET["folder"].'/*.jpg')); ?> it return : ["photos-animaux\/ani-01.jpg","photos-animaux\/ani-02.jpg","photos-animaux\/ani-02b.jpg","photos-animaux\/ani-03.jpg","photos-animaux\/ani-04.jpg","photos-animaux\/ani-05.jpg","photos-animaux\/ani-06.jpg","photos-animaux\/ani-07.jpg","photos...
I am new to php and webservices so pls bare with me The following is my webservice calling 2 methods from dataclass (registerCustomer and getCountries) <!-- a string array req param, used as a return for the getAvailable cars method --> <message name="response"> <part name="resParam" type="tns:strArray"/> </message> <!-- just a string...
What I'm trying to do is pull up profile info w/ the profile's comments. I get everything as expected. No error returned, array is formatted perfectly. My concern is the queries that are run. It runs one query for each ID to get its photo (the start of the query is noted in comments in the code below). I guess this is the only way to get...
Some have see that code : <?php echo stripslashes(json_encode(glob("photos-".$_GET["folder"].'/*.jpg'))); ?> it echo a really nice perfect string like that : ["photos-animaux/ani-01.jpg","photos-animaux/ani-02.jpg","photos-animaux/ani-02b.jpg","photos-animaux/ani-03.jpg","photos-animaux/ani-04.jpg","photos-animaux/ani-05.jpg","pho...
I have 2 database tables: Teams and Games. For the purpose of this question, we are dealing with football (soccer) teams and games. Each Game has exactly 2 teams, generally a home team and an away team although occasionally both teams can be neutral. My question is whether I should represent this data relationship using 2 foreign keys...
I'm trying to get indefero working on a webhost I'm running, and the /login URL simply appears to be redirecting back to the main controller. I assume I have a setup issue, and rather than bother the developers, I figure I can blunder through and figure it out. (I'm somewhat familiar with PHP). What I'm not familiar with, is if there'...
Hello all, I would like to count the occurrence of all commas in a very large text file (its has comma delimited data). Size is 28mb. I thought of loading up the text file and doing something like this: substr_count($text, ','); Good idea? Will it work? The overall task is to find out how many rows of data it has. When I count the n...
I've seen a lot of code recently formatted as the following: A: if ($var=='test'){ $var=Foo('blah'.$var1); }else{ // do something } Personally I don't like it and would prefer it as: B: if ($var == 'test') { $var = Foo('blah' . $var1); } else { // do something } I think it's much more readable (note the addition o...
Hi, I've been looking at Doctrine and it seems like a good way to manage models in my OO PHP application. I would like to create Models that have some optional properties. Rather than having null values in my database, I would like to create separate tables for some (all?) of these properties and give them a foreign key of the node w...
My project files are located on remote server in the folder. I access a file in this folder in this way: http://www.example.com/searchtest.html This opens a page with Input Box where user types keywords to search. The search script is a .php file located in the root itself. The script has to search for .html files with the name similar...
Hello, Is there any way, when using Doctrine, to create a table like another? I know in MySQL there is a function to do so: CREATE TABLE user2 LIKE user; and tables user and user2 will be identical. Can this be done in Doctrine? ...
Any Suggestions Would be very helpful! I need a little help getting a php client to connect to a .net WCF webservice and return a usercontext. I can get it to work in .net but not php. You have to sign in first which returns a usercontext that you pass to the other methods. Developer Help: The UserContext property gets or sets the...
I am trying to send data over to a cakephp (mvc) website, via $.post(). below is the code $('#testReq').click(function(){ console.log('Button Works'); $.post('http://play.anthonylgordon.com/usersessions/store/', {data:'test7'},function(data) { //data contains the json object retrieved. console.log(data.status); },"jso...
Lets say I have two separate databases, X and Y, on the same physical server. All of my queries currently run out of X. I find I have one table in Y I would like to be available to X for JOINS. So... now I keep a copy of the one table I need for both X and Y in both X and Y, but the data in Y is constantly changing, so the copy soon b...