« first day (256 days earlier)      last day (54 days later) » 
00:00 - 19:0019:00 - 00:00

12:01 AM
0
Q: multiple mysql query with group by

Mark Gilchristcurrently I am re factoring my code, At present I have $query="SELECT DISTINCT TRIPID FROM trips_info WHERE userid=$userid"; $results = $dbh->query($query)->fetchAll(); foreach ($results as $i => $row) { $iquery="SELECT COUNT(id) FROM trips_data WHERE userid=$user...

0
Q: Wordpress plugin. Get query from yahoo

user2946748I am creating a wordpress plugin but there is a problem getting the query. Here is the code: function getQuery($stockName){ $yql= 'select * from yahoo.finance.quotes where symbol in ("'; $yql = $yql.implode('","', $stockName); var_dump ($stockName); $yql = $yql.'")'; var_dump ($yql); re...

0
Q: Diffrent content depending of the weekday

Andre Andre RotaruI want to create a timetable for a class at school. What I need is some sort of script that uses client time to display a diffrent image according to each day of the week. So, for example, if it's sunday, I want it to display 'image1'. On monday, I want it to display 'image2' and so on. I realy n...

0
Q: Can't figure this error out: Parse error: syntax error, unexpected '}'

DerekI just installed a new piece of software, everything works fine until I click into one sectino of it and I get the error: Parse error: syntax error, unexpected '}' The line that it refers to I noted but it's just the line with a closing } The other questions on here and google with the same ...

0
Q: Where date for specific condition only

JamesOk so what I want to do is use start and end date for one condition/specific rows/rows with this particular id only. For example if order_status='1' ONLY then use start and end date and if order_status='2' then select ALL. I am using PHP to get this info from my database and then storing them i...

0
Q: $_POST checking variables and files

AristidesI have the following few lines: if ( (empty($_FILES["userFile1"]) ) or ( empty($_FILES["userFile2"]) ) or ( empty($_FILES["userFile2"]) ) ) { header("Location: " . "/"); } // required fields $required = array("userName", "userAddress", "userEmail"); // Loop over field names, make sure eac...

0
Q: Getting specific value from Ajax and PHP

BeardyI'm doing a name check from a lookup and the below is my jQuery var name = $('input[name=name]').val(); $.ajax({ type:"post", url:"assets/inc/namecheck.php", data:"name="+name, success:function(data){ var expire = $(data).attr('data-bind-name'); console.log(expire...

0
Q: Joomla VirtueMart: English words appear when german language choosed

Festus TamakloeI install successfully „de-DE.com_virtuemart.zip“ and „de-DE.VirtueMart_Plugins_Language_Pack.zip“) but some english words appeared when i change the language locator to German. Why some words like "Items(s)" bei cart and „Search Enter Keywords“ are not translated? Does somebody face already t...

0
Q: how to print out result of all class

Haikaany body can help me please, I real need help. I have a table name "Table1" with the following records of students. student_id | Name | Math | English | Sience | Class 1 John 100 90 89 std two 2 Simon 100 100 100 std two 3 Irene ...

0
Q: Get days of the week

jarne Hey guys so i'm making this web app just to train my coding skills but i'm stuck. I need to find a way to find out how many days are left from the week and what date they are. So lets say we're monday 2013/04/11, they're 5 days left from the week (because i have a today and tomorrow section alrea...

0
Q: Joomla! <base href...> is wrong

dollarvarI have locally downloaded Joomla! 1.5.22, my new job, from a production server. Now I cannot find the place to change the Base URL. I already fiddled around with the JURI class in uri.php, but to no avail. Then I deleted all the entries from SH404sefand the canonicalization is off. Has anybody go...

0
Q: Server ignores cUrl code lines php

Fond Processoriam using that php code in the localhost and working fine $ch = curl_init($src); curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true); curl_setopt($ch, CURLOPT_NOBODY, true); curl_exec($ch); $url = curl_getinfo($ch, CURLINFO_EFFECTIVE_URL); when i move it to the remote server the script ignores th...

 
12:49 AM
0
Q: How do I programatically search Google Plus for posts via the PHP library

RedLeaderI'm trying to get my head around how to use Google's PHP library to search Google Plus using the API. I want to create a command line script that can be run regularly (cron job) to search Google Plus for a key word and then store the results in a database. I will then have a website (moderation...

-1
Q: How can make Display Error after Refresh a Page?

Lord EhsanHow Can make Diplay Error For this page after refresh ?? <a href=\"index.php?do=pvp1:".$row["id"]."\">

0
Q: Array Fails To Use String Parameter

user2195574I've spent the last 20 minutes trying to figure out why, when using AJAX, my string value is failing to work. I have a form that, when submitted, sends the data to evo.php with a $_GET value id of say "01". The first thing I do is assign the $_GET value to a local variable $id by means of $id =...

 
1:13 AM
0
Q: pagination Won't work as it should

casperHello i have been trying to make a pageination script, but in the 1 2 3 4, it wont show the last number, i really have no clue how to do this. heres the code: ?php $per_page = 3; $adjacents = 5; if(isset($_POST['search'])){ $type = $_POST['type']; $pages_query = mysql_query("SELECT COUN...

-1
Q: Remove last to digits of filename

DaAwesomePHow can I remove the last two characters of a filename in PHP? http://www.nws.noaa.gov/weather/images/fcicons/tsra50.jpg # becomes http://www.nws.noaa.gov/weather/images/fcicons/tsra.jpg and http://www.nws.noaa.gov/weather/images/fcicons/hi_shwrs60.jpg # becomes http://www.nws.noaa.gov/weathe...

0
Q: How to add Google Fonts in wp_enqueue to WordPress?

Bakó AlpárI need a little help about wp_enqueue_style function in WordPress. I made a WP theme, and I have an Admin Panel which has a Typography tab. The admin can easily change the theme font styles. This fonts was Google fonts. There are 3 different option. One for the navigation, one for the heading, a...

0
Q: Can't get attr id with jquery

Gustav TrennertI'm on a symfony application (2.3) using http://www.symfocal.com/ I try to change the way the calendar is diplayed but I have some trouble with jquery : Here's the part of the modified code concerning my problem. The twig file with jquery : <script> ... jQuery(document).ready(function() { va...

0
Q: htpasswd password protect site

Milan MilosevicI have member area and im try protect access to this url http://site.com/wp/ with htaccess, all this working fine , here is code from my htaccess.. AuthName "My Site" AuthType Basic AuthUserFile /home/site/.htpasswd AuthGroupFile /dev/null require valid-user But in same directory http://si...

0
Q: Wrap post type post with nested child post inside ul

Bayu Idham Fathurachmanthis is my first question.So , please be nice :) I have some problem when trying to achieve this HTML structure in wordpress loop. <ul class="dropdown"> <li>Normal Text Without Child</li> <li>Link Text Without Child</li> <li class="has-child"> <a href="#">Link Text With C...

0
Q: Advance array pointer in foreach loop

Wesley MurchI'm trying to create an associative array from linear array: $items = array(1, 2, 3, 4, 5); $assoc = array(); foreach ($items as $item) { $key = $item; $value = next($items); $assoc[$key] = $value; } print_r($assoc); Desired output: Array ( [1] => 2 [3] => 4 [5] => f...

-1
Q: How to create advanced search with php and sql

besiI have a drop down list at html with an text field and one search button now I'm trying to create a sql db and to connect those with php but i have no idea how i can do that because its my first time using php and sql.

0
Q: Adding and removing a year from date

Ricardo CapistranI would like to add and remove a year from a date I have this code: $yearbefore = date("Y",strtotime("-1 year")); $yearnext = date("Y",strtotime("+1 year")); This will add and remove a year from current date, but what if I want it from another year in a var? $year = "2010"; How can this be...

0
Q: API for open source static analysis software to find security vulnerabilities in the code and visualize it nicely

user2813808I need to develop a website to scan a web app. This will find security vulnerabilities in the code and visualize it nicely. User will have option to remove false alarm and use his own rules. I need to use any open source static analysis software under this cover. Are there any api's to use in my...

0
Q: What type of programming is needed to run an IOS app

Mnramos92So there are websites that use dynamic web pages and use PHP for this. Also websites need to use SQL to run information in their server databases. How would an iOS app do this? Through the same type of programming (PHP&SQL)? I'm a student only looking to learn. Thanks!

 
1:49 AM
-2
Q: Find if last two characters in filename are numbers

DaAwesomePI want to see if the last two characters/digits in a filename are numbers in PHP. if (CODE HERE) { // runs script because last two characters are numbers } This should set it off: http://www.nws.noaa.gov/weather/images/fcicons/hi_shwrs20.jpg The last two digits are '20' This should not: h...

0
Q: PHP Site Generating Strange Pages

user2946889I have a dynamic PHP based site and I've recently noticed its generating a lot of weird pages like this: http://www.festivalsnap.com/festival/3151748-16th+Annual+Magnolia+Fest+/hotels/3151748-16th+Annual+Magnolia+Fest+/ticket/hotels The site architecture should be like this www.mysite.com/festiv...

0
Q: PHP Session - not saving

Ákos FodorI'm working on an admin page for my site, but I found a problem. My code worked perfectly with Wamp (and still working in Chrome, but not for other people, or in other browsers). So, the problem is that my site don't save the session variable after header redirecting. (Another thing I can't figur...

0
Q: How to redirect back to index page and display modal pop up as per redirecting? PHP

Jben Kayei have an index page which asks for input. after submit button is clicked, the input is processed in another .php file (process includes using imagecreatefromjpeg and mysql queries). now, it needs to redirect to index again and show a modal popup saying thank you. i am able to redirect to index p...

0
Q: how to fetch just new images on a weekly basis-PHP

Pasargadthere is a shared drive with the server; in that shared drive there are some images which are coped by the photography department regularly. I have to write my web service and use a scheduler to call it (lets say every wednesday) and if there are any new images (from the last call(check)) I have ...

0
Q: Put a Array in another Array by comparing their values

Matthias StähleI got two arrays. Array A with Soccer-Player positions and array B with Soccer-Players. Every Player got a name and a position. Now I wanted to split array B in the different postions of array A and re-order it in one array sorted like the positions in array A. The arrays look like this: Array...

0
Q: Remove myspace opensocial contents so it stands alone without any opensocial

Luca Braysonfor example the stuff like this: params[opensocial.DataRequest.PeopleRequestFields.FILTER] = opensocial.DataRequest.FilterType.ALL

0
Q: Using Array Variables For FILE_GET_CONTENTS

WhoshooterI have a script all done now and everything has been debugged and it works, except for the last hurdle. This script grabs pertinent information on bank web sites, takes that data and uses it to populate a template and then it's all posted to Wordpress - BUT I get an error because the file_get_con...

 
2:19 AM
0
Q: mysqli last insert id

user2926655I would like to associate the image with firstname, lastname...how can I retrieve the last rowand use it to insert to the other table? I tried $image = $mysqli->insert_id; then binding but it doesn't work. Can someone help me out? $image = $mysqli->insert_id;//this should come from table2 $stm...

0
Q: Issues with implementing SAML 2.0 and php

ValI am trying to implement a service provider in PHP, that should be authenticating against a corporate IDP server, running a Novell Access Manager. I am currently using a SimpleSaml PHP library. I have generated SP description using a builtin metadata converter, and my SP seems to work fine with ...

0
Q: How do you get woothemes shortcodes to work on an archive page of product attributes

lifeIsGoodI am not really sure how to ask this question, however if you have a look at this link you will see what I mean http://www.skirentalwhistler.com/skill-level/beginner You will see that the shortcodes for a [box] are not being executed. If you browse a single product, the shortcode works fine - ...

 
2:37 AM
0
Q: Facebook PHP sdk error?

Milan Sanda Srii downloaded facebook php-sdk and i update it with my app id and app secret. then i ftp it in to my server. it is a windows server. but when i run the example.php in example folder it shows always not connected even when i clicked on "Login with Facebook" button. but it returned a url like this...

-3
Q: Nimbuzz ! API ( Chat Buddy )

user2946923do any one of you used Nimbuzz ! API or Nimbuzz ! Developers Program http://developer.nimbuzz.com/ Uses an php script the problem this that the program view correctly in the website http://wadalamalhuda.cwahi.net/ but did not work will sign in to nimbuzz but adding this Nimbuzz ID : bot wadala...

0
Q: parse json values in php and displaying in a table

NarenHere is my html, <html> <head> <script src="js/jquery.js"></script> </head> <body> <input type="text" name="query" id="queryBox"> <button id="load_basic" value = "button">search</button><br/> <div id="result"></div> </body> <script> $.ajaxSetup ({ cache: false }); var a...

0
Q: destroying old session, making new, but php still refers to old session

olliTook me a while to tackle this problem to it's exact cause, but here's what seems to be happening: I have a session. I want to completely kill my current session and start from scratch, with a brand new session, that has a blank slate. So this is what I do: public function unregister_session()...

 
2:54 AM
0
Q: My text area will not get larger when I change the number of columns

MikeI have an html textarea that is coded like this in php: <form> <p> <strong> Your Notes: </strong> </p> <textarea rows=\"8\" cols=\"500\" "></textarea></p> <p> </p> </form> My problem is I keep upping th...

0
Q: Exactly, which MySQL queries throws results that need to my freed by mysqli_free_result?

Pablo J. MartínezI want to exactly know which of MySQL queries throws results. I mean, I have read that there are some queries like INSERT and DELETE that don't need to be freed. Exactly, which one of those I need to free? I don't want to be using mysqli_free_result in places which not makes sense at all. I kn...

0
Q: Going deeper into facebook's graph: collecting friends available data

Pavelescu RazvanI am building an PHP website using Facebook Graph API's and I can only read and collect very basic data. I managed to collect the one-line informations from my profile: Ex: $user_profile['hometown']; $user_profile['bio']; $user_profile['name...

 
3:13 AM
1
Q: php and html output and display UTF-16 characters

MichaelMitchellI am having some difficulty understanding how to output a UTF-16 string with PHP and having it properly displayed in the web page.. The string is from a game (it is a name) and can contain any of the characters. I would like to output the given string "ムName" as &#12512;Name which would be inte...

-1
Q: PHP parse large CSV in multiple passes

Robert82I have a large 500mb csv file with over 500,000 lines, each with 80 fields. I am using fget to process the file line by line. Because of an execution time limit on the PHP file by my hosting provider, I can't process the whole file in one run. I tried using ftell() and fseek() to remember the l...

0
Q: how to loop through the contents of a php array?

NarenI have a php array which I got as a response from a server so I can't change it, print_r($array); // result is below Array ( [responseHeader] => Array ( [status] => 0 [QTime] => 1 [params] => Array ( [fl] => title [indent] => true [q] => java [wt] => json ) ) [response] => Array ( [numFound] =>...

 
3:31 AM
0
Q: PHP MVC form error checking

user2503750I have a class that contains two functions, one called signup() and one called p_signup(). p_signup() is where my form is processed that is sent to the view in signup. I am error checking in p_signup with an errors array -- how do I make this errors array available to the the view that I send th...

0
Q: How to use fopen to edit php file

吳承諺I know fopen function can write line in php file, if I have a config.php with many const, for example: define('NAME', 'David'); And I want to post another name to replace default value, is that possible?

0
Q: Display Store Products in Row from MySQL table (PHP)

user1985117I'm stuck - I'm pulling store items from a MySQL table for an online store. The query returns the items. Normally, I would I use the following, which lists each product in a separate row: <table> <?php while($rows = mysql_fetch_array($productListResults)){ ?> <tr align="left"> <td><b><?php echo ...

0
Q: Wordpress: Check if date is today or has passed

PHPnoobI have a custom field that spits out the date in the format dd/mm/yy I am using this to display it on the front end... <?php echo "<p>" . get_post_meta($post->ID, 'duedate', TRUE) . "</p>"; ?> ...which outputs... <p>02-11-2013</p> But what I need to do is insert a class if the date is toda...

0
Q: Creating a multidimensional array

Jess McKenzieI have the following response and I was wanting to know how can I turn it into an multidimensional array foreach item [0][1] etc Controller $rece Response: array(16) { ["digital_delivery"]=> int(1) ["original_referrer"]=> string(11) "No Referrer" ["shop_rule_us_state_code"]=> string(1) "0" ["su...

0
Q: php parsing csv with ftell

Robert82I have a 500mb csv file with over 500,000 lines, each with 80 fields. I am using fget to process the file line by line. $col1 = array(); while (($row = fgetcsv($handle, 1000, ",")) !== FALSE) { $col1[] = $row[0]; } Because of an execution time limit on the PHP file by my hosting provider (12...

0
Q: Malicious PHP Shell Upload via Image

user2947019I read online that it is possible to write malicious PHP script and disguise it as a JPG file to bypass the filter (uploading images only), i was wondering how to do this with a malicious PHP shell. if i pentest this site with this method will i need more info on the site? (PHP version, how the f...

0
Q: PHP Session Storage

Brendon RotherOk so what I'm trying to accomplish is a simple login page(adminlogin.php) that then goes to a small php file(session.php) which starts a php session and stores the posted data in session variables. Once this is finished the php file redirects to a admin menu page(adminmenu.php). on the menu page...

0
Q: saveAll() not saving associated data

DaveBelow is the association, the save call, and the data going to the save. It generates the UPDATE query for Event, but there are no queries generated to save the associated EventInstance. It says it's saving fine - no validation errors..etc. And I have no validation array on the EventInstance m...

0
Q: PHP: How to convert a string to numbers that include math operations in it?

Rosamunda RosamundaI mean convert this: '1+1' to this: 1+1. I´ve found this answer, that says that you can perform math operations on strings, like this: $num = "10" + 1; But it´s not the same here, because the math operator is inside the string.

0
Q: mysql_fetch_assoc data to COOKIE in user browser

Gowtham RajI had data in mysql, where it does not need any security. I had a sql query string to get the data out every time using mysql_fetch_assoc. So, I planed to store data in users browser.To reduce no of quires to sql. if (!isset($_COOKIE['countries'])){ $query = "SELECT iso,name FROM sel_c...

0
Q: PHP: AJAX request to PHP

JeffSo I'm having a problem with including a file on a PHP page called from an AJAX request: $(document).ready(function() { $("#image-status").html('Processing images...'); }); function process_images(files) { $.ajax ({ type: "POST", url: "includes/imageprocessor.php", data: {files: JSO...

-2
Q: Cannot modify header information - headers already sent by (output started at /home/boysgene/public_html/admin/login_now.php:3)

user2946964 0 && $row['userty']== user && $Security == $hidden) { $_SESSION['name'] = $adminName; $_SESSION['password'] = $adminPassword; header ('Location: ../Users/home_user.php'); } else if(mysql_num_rows($result) > 0 && $row['userty']== admin && $Security == $hidden) { $_SESSION['name'] = $adminName; $_SESSION['password'] = $adminPassword; header('Location: adminindex.php'); } else { header('Location: in...

0
Q: updating mysql two cloumns

user2947043I have a script which searches database and dispays the list of users whose attendance are to be marker by his supervisor. Supervisor marks attendance and feels remark and submits the form. I am able to insert attendance in mysql database but remarks column is being not updated. Pls Guide. Fo...

 
4:19 AM
0
Q: Using $_SERVER['SCRIPT_NAME'] to instantiate controller

astinxI was working with a MVC architecture in my php webapp. My architecture it's pretty simple, if I send a request to an url in this way localhost/Dispatcher.php?class=SampleController&method=sampleMethod this will instantiate the controller SampleController and invoke the method sampleMethod of thi...

0
Q: return an array from database

Reaper AxeI have a problem using str_ireplace with an array returned from a database table. I want to use a table to hold bad words that will be filtered from a chat. $msg = "some user input, with a few bad words."; //(not putting bad words here, just an example) $words = $this->db->query("SELECT * FROM t...

 
4:31 AM
0
Q: ajax, jquery and Iframe (creating a message box system)

user2506760I'm trying to create a sort of mail on my site. So I have a table that contains three columns, let's say (for simplicity , but in reality) , with the two int fields ( from, to ) and a timestamp (date of sending ) a part of my page , I display a list of messages with a group by to to group all m...

0
Q: Not getting column title at the first page in fpdf

lalith458I am using below link to create a pdf document from mysql table data using php fpdf http://www.fpdf.de/downloads/addons/30/ but i am not getting column titles at the first of the pdf page,and getting column titles on the next pages. can any one tell me how to get the column titles at the first ...

0
Q: Unable to include "vendor/autoload.php" after install Composer on Ubuntu

ConnorLaCombeI'm just getting familiar with Linux servers and I'm trying to install Composer on my Ubuntu server. I think everything installed correctly except when I try to include Composer's autoloader I get a PHP error: Warning: require(/usr/share/php/opencloud/lib/../vendor/autoload.php): failed to op...

0
Q: AJAX Wordpress pagination randomly died

user1512787So evidently the devil lives on my client's server. I installed an AJAX pagination script to avoid the entire page loading when the "next" arrow was clicked on the post feed. It was working perfectly and now, for some reason, without having made any changes at all, it doesn't anymore. Here's t...

0
Q: Values not being transfered from JS to php

MikeI have a JS script of: function addTasteingNote(userID,beerID) { //get values var note = $('#note1').val(); var ajaxSettings = { type: "POST", url: "a.php", data: "u="+userID+"&b="+beerID+"&n="+note, success: function(data){ } ...

0
Q: Is there a way to email the results outputted by the PHP retrieval?

Tim ValishinI have a form that works as a search through database, when user enters lets say ID 123, the full information on that person comes out in php page (it outputs in a table) so my question is, is there a way to email the table that was generated to an email provided by the user?

0
Q: Dynamically Add Multiple Cgridview on a single Page

MaxxI'm trying to figure out how to let the user add any numbers of tables or CGridview on a single page. So right now the page has two gridviews in it which will stay fixed. Now i want to add an add button somwhere, clicking on which will give the user another gridview, and so on. How should i proc...

0
Q: PHP: identical echo statements working in one place but not in another

Vincent TencateI've made a page where users can upload statuses, which are then displayed in a readonly textarea. My problem is, I want to display the time the status was uploaded in a textarea underneath the one displaying the status, but this is not working. I can display whatever I want in the first textarea...

0
Q: Using maxmind's geoip to lookup city name based on zip code posted.

fabio User submits a form with a Postal code field. Use postal code to get corresponding city name. Does anyone know which function I can use to reference the post zip code with MaxMinds GeoIP database? Can't find any relevant documentation. Thanks!

0
Q: Php cookie is not is not setting

WAQAS KHANPhp cookie isn't setting I'm trying the code setcookie("TestCookie", $value, time()+3600); but after the code when I print all cokies it does not print this cookie foreach ($_COOKIE as $key=>$val) { echo $key.' is '.$val."<br>\n"; } it shows the result PHPSESSID is na9db7pfdgoldk...

0
Q: Flickr uploading with PHP

croarI am trying to upload images to Flickr via the flickr api and PHP. However, all of the documentation for things like phpFlickr don't seem to work. Maybe Flickr changed something. What's the best way to do this currently. I want to a) upload the picture from a form and b) get the URLs in 2 or 3 re...

0
Q: Pop Up message is not open

vaibhavwhen i am using set_flashdata() function or print() before the redirect() function in CodeIgniter. it's not working. what's the reason behind this or can i use another function to popup the message on the screen.

0
Q: Why Isn't This Form Auto-Submitting Upon File Select?

Alex ParkerBelow is the code of the page, however, you will see in the head that I have put in javascript that is supposed to check to see if there is a file selected via the file upload input field located at the bottom of the code. After it detects the file selection, then it is supposed to automatically...

0
Q: PHP DOMDocument: DOMDocument::loadHTML(): Empty string supplied as input?

lauthiamkokWhy do I have this error which I don't understand at all!? It is provided with string but DOMDocument gives me an error message on my live server! It is running php 5.4 on my localhost and live server. $item_html = "<p>hello hello</p>"; $dom = new DOMDocument; $dom->loadHTML($item_html); var_du...

0
Q: redirect after an ajax call with auto increment value from database

MikeI have an ajax call that looks like this: { //get values var note = $('#note1').val(); alert(userID); alert(beerID); var ajaxSettings = { type: "POST", url: "addTasteNote.php", data: {u:userID , b:beerID ,n:note}, success...

0
Q: How to automaticaly convert decimal into number not a string in php?

fr05t1kHow to make auto convert a decimal data type into number not a string in php? I changed data field into decimal(4,2) from double. I have many checks like if ($row->field) And $row->field === 0.00. When it was double it's ok. But when I get decimal in php it's get string type and '0.00' it's TR...

0
Q: What are some efficient ways to set up my environment when working on a large/complex remote site?

PrefixHello fellow Programmers, I am still a relatively new programmer and have recently gotten my first on-campus programming position. I am the sole dev responsible for 8 domains as well as 3 small sized PHP web apps. The campus has its web environment divided into staging and live servers -- we de...

0
Q: share button not fetching images

Chinthui have my website hosted in godaddy server.The site is done using codeigniter framework.There is social meadia plugins in most of pages.When i click share buttons it is not fetching images or page content that was working properly in my old test hostin site url is http://artinnmedia.com/index/g...

 
5:37 AM
0
Q: Creating more then one array

Jess McKenzieBelow is a response I get from the controller. How could I turn this into more then one array as currently all the data is in one array? Response: array(16) { ["digital_delivery"]=> int(1) ["original_referrer"]=> string(11) "No Referrer" ["shop_rule_us_state_code"]=> string(1) "0" ["subtotal_e...

0
Q: Submit form after success return after ajax call

vishalI validate my form with both client an severside scripting first I validate it with jquery then it goes to php validation php and if it returns success or something like that I want to submit the form but some how the condition does not work. How ever in html err_msg I get success text but not w...

0
Q: php code inside a href tag not working

LmxcI would like to redirect to other pages but the = sign isn't working, the page name, the title, and the id are coming from database. I tried putting . before the = but that doesn't work. I think this should be simple but couldn't figure it out. can someone help me out? echo "<a href=".$row['pa...

0
Q: I want to update mysql table after successful redirection

user2866454I am trying to make a php website. I need help for that. I am creating a url shortner and I need to update total views of links. I want to UPDATE mysql db after successful redirection. for eg, I am visiting a link abc.in/ggl which will redirect me to google site. Total views of the link is 20....

0
Q: data showing in one array. How to put into its own array

Jess McKenzieHow can I make it so that every time the foreach is run it adds it into its own array instead of one like below? Response: array(16) { ["digital_delivery"]=> int(1) ["original_referrer"]=> string(11) "No Referrer" ["shop_rule_us_state_code"]=> string(1) "0" ["subtotal_ex_vat"]=> string(4) "9.99...

-1
Q: How do I run a loop with a variable number of iterations in constant time?

SaurabhI have the following PHP code: $count = 100000; $array = array(); for($i=0,$i<=$count,$i++) { array_push($array,mt_rand(1111111111111111,9999999999999999)); } The time to execute this code will increase as I increase $count. I am looking for a solution to keep the time to execute constant ...

 
6:18 AM
0
Q: why not login with administrator or doctor?

user2947157when the log can not go to the main page and the session is not active whats wrong in this code?? ` $_SESSION['nama'] = $data['nama']; $_SESSION['email'] = $data['email']; $_SESSION['password'] = $data['password']; }else{...

0
Q: magento:categories are not appearing when editing products

kevinzdpI have one magento installation with 2 websites.I want to set a subcategory from website 1 as rootcategory of website 2. I copy app/code/core/Mage/Catalog/Model/Resource/Category/Collection.php to app/code/local/Mage/Catalog/Model/Resource/Category/Collection.php update around line 414 $this-

-3
Q: php calculate late fees every 30 days

user2947187ok, I am trying to figure out how to add 1.5% to a total number from my DB every 30 days. If my balance today is $600 and I have not paid it in 30 days, it adds 1.5%, but if I dont pay it in 60 days, it adds 1.5% on top of the first 30 days late fee. Here is what I have... if ($invoicedate <= "$...

0
Q: PHP Time Subtraction and Conversion

Eric ZebrowskiIt's hard to articulate the problem I'm having in the title, but here's the scenario: I'm working the backend of a 3-tiered exam taking website. I'm currently updating my function used for when students request an exam. The exam has start and end dates and times, as well as a time limit. What I ...

1
Q: how remove duplicate in array with clause

user2947193How to remove duplicate in array if key have same name value and same file value(or file have empty value), i just want to remove index 2, please help me... Array ( [0] => Array ( [NAME] => E-Library [ID] => 27 [FILE] => Lorem Ipsum ) ...

0
Q: is that a bug of mssql_query()

iacnats@ $db = mssql_connect('127.0.0.1','sa','ijg098u'); if (!$db || !mssql_select_db('test') ) { exit('db connect error'); } $str = "insert into comments(name, comment) values('$name', '$comment')"; if (!mssql_query($str)) { exit ('db insert error'); } When $name or $comment has strange char...

-1
Q: Ward's Method Algorithm

Kendra 游I want to use ward method for clustering, I've read the algorithm at: https://www.google.com/url?sa=t&rct=j&q=&esrc=s&source=web&cd=1&cad=rja&ved=0CC0QFjAA&url=http%3A%2F%2Fiv.slis.indiana.edu%2Fsw%2Fdata%2Fward.pdf&ei=dZp0Up6rE8KSrgfs6IHwCA&usg=AFQjCNHI8F6_k-kvmyZiksytTWc_VwiMrQ&sig2=2pkdQ30RvV...

0
Q: PHPUnit Exception

user2909892I have the following code that creates a new user. I am using PHPUnit to prepare test cases but however my code coverage is unable to cover the exception case i.e. throw new Exception(__CLASS__ . ': Invalid data');. Can someone please show me how to cover the exception case in phpunit using asse...

0
Q: Understanding SOAP and WSDL for PHP

Honey BadgerThere is a web service that I need to connect to. I have been given a URL which does not lead to a WSDL file. Instead, I've been given a bunch of WSDL files which I was told that I must store locally. So I'm very confused it's not the way I normally connect to a web service. For example, when ...

-1
Q: PHP Update dynamic list

CarlWhat I'm trying to do here is when I select a option from the dropdown menu, the form will post and process the request. However, I cannot find a way to associate the entry id to the post request. Here's my current script: if (isset($_POST['check'])) { echo $_POST['check']." - ".$_POST['t...

0
Q: once resized image is offered as download, hide the loading gif

gurungNote: Please go through the question once completely and if there is a mistake in my approach/question give me a chance to correct it, instead of any hastened or uncreative reaction. I have a little image resizing script which promptly offers the resulting resized image as a download. If this wa...

0
Q: PHP Mkdir failure

user2936438Here is my code: // Code To Execeute $id = uniqid(); $dir = "video/"; $title = $_POST['title']; $thumbnail = $_POST['thumbnail']; $video = $_POST['video']; $date = $_POST['date']; $description = $_POST['description']; //Clean up multiple dashes or whitespaces $newtitle = preg_replace...

0
Q: May i setup cpanel in openshift app?

Sudipta DharaI have a openshift php app. I want to setup cpanel for that. So, is it possible? If yes then please suggest how to do that.

0
Q: PHP help - only need a simple explanation

cactusboatAlright, I'm trying to understand how this PHP code works. <?php $test = "success"; $primary = "test"; $id = ${$primary}; echo $id; ?> I know the output is "success" but I don't understand how it works. What i understand so far: test variable has the string "success", primary variable has t...

0
Q: Facebook Graph Explore for /me/posts returning different from PHP SDK

Eco NomVery strange, if i search for /me/posts on the FB Graph Explorer, it returns only the posts, nothing else. If I run it inside php, like this: $feed= $facebook->api('/me/posts'); It returns also all other type of stories. I am filtering them at the moment, looking for the name field, but it wou...

0
Q: How to decode base64 sting and store base it in mysql db in php

HarshI m new to the php web services and I m doing it first time.I m receiving an encoded base64 image via post body in my web services and i want to decode that base64 image and want to save it in MySQL DB how do i do that because i not getting the exact result that i want. Thanks in advance

0
Q: can not log in with administrator?

user2947157what is wrong if my code or my database? my code if(isset($login)){ if($sbg=='administrator'){ $login = mysql_query("SELECT * FROM administrator WHERE email='$email' AND password='$pass'"); $rows= mysql_num_rows($login); if($rows==0){ ...

0
Q: Timestamp update issue

Basel ShbebI have a MySQL table for guesses for matches , when any user make a guess the table take the current time-stamp of that guess. And when the match finished the table will update the match result field. My problem is that when the table update the result it updates the time-stamp also how I can sto...

0
Q: too many redirect while redirecting to SSL

user1688346I am trying to redirect to https but it doesn't working with the code below which i put it at the beginning of index.php <?php if(!isset($_SERVER['HTTPS']) || $_SERVER['HTTPS'] == ""){ $redirect = "https://".$_SERVER['HTTP_HOST'].$_SERVER['REQUEST_URI']; header("Location: $redirect"); }

 
7:16 AM
0
Q: 403 Developer Over Rate

KerryI don't know why I am getting this error. And, it used to work fine and when I try to make 20 searches on my website I get 403 Developer Over Rate error and I need to wait till next 1 hour so that my session will be released. Here is the total error response. Fatal error calling curl:https://ap...

0
Q: Printing direct descendants of a category with WP_Query

blakeSo I'm having trouble printing just the direct children of a category on a page. Here's my code: $category_id = get_cat_ID('destinations'); $args = array('child_of' => $category_id); $categories = get_categories($args); $args = array ( 'category__and' => $categor...

0
Q: jquery validation setdefault prevent form submission but submit it after ajax not working

vishali submit my form then it all validation using jquery are okay it goes to ajax page then it returns and submit the form after the ajax event. i prevent my form submitting using jquery validation setdefault method but if i use this method after success function the form does not submit and stops an...

0
Q: Zend Opcache auto flush (reset?)

Adriano BatistaI may simply be terrible at research, but I can't seem to find an answer to this. I have opcache set to use 128M of memory (that's all I can allow it to use at the moment until I get some more RAM for my VPS). WHAT IN THE WORLD HAPPENS WHEN OPCACHE HITS THAT LIMIT? I can't find the answer to that...

0
Q: Running javascript inbetween php tags

user2947268I want to run a javascript inbetween php tags, but I am not quite sure how to call it. All googling results in client side vs server side questions. ?> <script type="text/javascript"> function extend() { var temp = document.getElementBy...

0
Q: display a php page after executing it from ajax .post method

Chaithanya VarmaI have a html page with a form id="date_select" and a div block with id="display". index.html <form id="date_select"> <span id="date_select">Select date to display forms:</span> <input id="date" type="text" /> <input id="date_submit" type="submit" value="submit" name="submit"/>

0
Q: document.getElementById('id').selectedIndex does not read the index but the code itself as string

Mr. Programmeri have a JavaScript here embedded in a PHP script "echo". when i use the document.getElementById('list_subjects').selectedIndex in alert box it gives the result but when i use it in a php array variable. it says undefined index. i did (int)$index to convert it a integer but its output only is alw...

-1
Q: Why can't I see my php code rendered on page?

natecraft1Just getting started with php. In index.php I have <?php echo 'test'; ?> and when I go to localhost:8080/php/index.php I see 'test'. However I made an HTML file index.html with this code: <html> <body> <?php include 'index.php'; ?> <h1>Welcome to my home page!</h1> </body> </html> but...

0
Q: Table alignment in php

user2947210I am new to php. I am trying to create a page in php with dreamweaver. I have table to contain. It is perfect in html and also viewed live in dreamweaver. However when opened as php with the help of Xampp alignment goes. The row which I have kept below is moving to right side. regards Sajeesh

0
Q: how to convert a blob into video?

user2809576i want to change an blob into video format. Before this i try to convert the blob into image by the following code. <?php $data = 'iVBORw0KGgoAAAANSUhEUgAAABwAAAASCAMAAAB/2U7WAAAABl' . 'BMVEUAAAD///+l2Z/dAAAASUlEQVR4XqWQUQoAIAxC2/0vXZDr' . 'EX4IJTRkb7lobNUStXsB0jIXIAMSsQnWlsV+wULF4...

0
Q: Zend From New Element Injection

Faisal RehmanI have a Zend_Form with 2 fields 'Username', 'Email' and in my database user table have 3 fields: 'Username', 'Email', 'Active' I am using same element name as database field name. My question is, Is there any way to validate form elements after form post which are not part of the form. I mean...

0
Q: How to test application logic not in a class?

TominatorI have some huge PHP legacy code that doesn't use any framework, and the design is something like this: user loads a page.php page.php checks "do I need to respond to parameters in $_REQUEST? if so, I react and die out if not, I render the original page There are a lot of "classes" but they a...

0
Q: how pass mysql_query result in query string?

user2881770How can i pass the array result in php is it possible that it can pass the mysql_query result with the query string to use that resulted value in another page. $qry="SELECT machine_equiptype ,COUNT(*) FROM project_machinelist WHERE machine_status='$wf' group by ma...

0
Q: how to insert MathMl Language into my sql database column

Farhan DharsiI want to create online math quiz and all questions and answers and correct answer via using MathMl Language. But how do i insert MathMl Language into mysql database? Question: what kind of function help to insert mathml language ? Example Of MathML Language <math xmlns="http://www.w3.org/1998...

0
Q: is it good to use self:: or static:: on non static function?

user2707590i am doing some oop in php and when i just wanted to know if its good to do this? when i use $this->functionName(), it works fine and i even tried with self:: and static:: and they work as i expected: self:: will use the parent method implementation and static will use the last implementation of...

0
Q: Iterating through loops in twig

David Eugene PetersonI'm trying to iterate through objects in Twig, but am having no such luck. Here's what I've tried so far. Here's my default controller method: public function ReturnPhonesAction() { $phonequery = $this->getDoctrine() ->getRepository('TravelTravelBundle:Phone') ->find...

0
Q: Beginner PHP / SQL / AJAX - Query not working when parameter passed to server side script

user2469528I am beginning to learn PHP + AJAX + SQL. I cannot seem to crack the syntax issue I am running into. I am running the latest WAMP version on a server in my network as the test environment. I have the following script in my INDEX.PHP (from W3Schools.com): <script> $(document).ready(function() { ...

0
Q: PHP - strange syntax errors with brackets inside multidimentional array

Obmerk KronenI have a simple code like so : class o99_custom_fields { /** * @var string $prefix The prefix for storing custom fields in the postmeta table */ var $prefix = 'o99_'; /** * @var array $customFields Defines the...

0
Q: PHP Startup: Unable to load dynamic library (NEW RELIC)

Adriano BatistaOk, so the folks over at New Relic have not been very helpful with this so I am asking here to see if one of you nice folk can help me out :) I am running Ubuntu 12.04 with Nginx and the latest PHP. The story goes like this: I tried to install the new relic PHP agent per the instructions for ubu...

0
Q: Changing input to link how to do that?

Mike SantI need a code that when i get http://www.youtube.com/watch?v=ktvTqknDobU That the php script rename it to http://bloxhotel.nl/video?watch=ktvTqknDobU And after done that load that page sorry for my bad english i have tried this <form action="welcome_get.php" method="get"> Youtube Link: ...

 
8:21 AM
0
Q: How to implement this in accordance with the programming best practice in PHP

veeveeoorFor describing my problem I will use the certain analogy which is simpler for analysis and in my opinion well is reflecting my problem. Let's assume that there is a Library class which contains two lists: of books and of bookshelves. In PHP both lists it is easiest to implement as arrays and I d...

-3
Q: Why PHP "echo" is named "echo"?

waredI won't be surprised if this question is closed :) I was wondering what the word "echo" means and why it is used as a name for the PHP output function. Even though the translation has the same meaning in french, it doesn't really enlighten me about this choice. Is it a conventional name used by ...

0
Q: How to print over the internet

GameDevGuruI have an in-house web app that allows users to print name tags. I would like to make the user experience very simple by printing their name tag with a button click. On the backend is a dynamic PHP script that creates the image. There is no need to confuse users with the print dialog. I've set u...

0
Q: Get select option menu in javascript/jquery

user2933671I have a select option in a form like this <select id="name" name="name" onblur="date()"> <option value="RAN">RAN</option> <option value="REE">REE</option> <option value="SAM">SAM</option> <option value="SEJAl">SEJAl</option> </select> I want to get the value of the selected it...

-1
Q: How can I use curl instead of file_get_contents

XtremeI have the following code class Flickr { private $apiKey = 'YOUR API KEY HERE'; public function __construct() { } public function search($query = null) { $search = 'http://flickr.com/services/rest/?method=flickr.photos.search&api_key=' . $this->apiKey . '&text=' . u...

 
8:46 AM
0
Q: Extract a node value from a xml file and update that value with php

koshi18I have a shopping catalog with a button at the end of the each row to add the item to a shopping cart.i need to increment the "Quantity on hold(IqtyOH)" by one each time the user press the add button.I need to modify the xml document according to that. here is my xml file just to get and idea. <...

0
Q: How to compare arrays and objects to find a match PHP

salivanMy first question is, how do I search values of my array inside the objects array [words] and return object if match is found? How do I search for a better match? In the example below, second object is a better match with 2 words in common, rather than first with only 1 match. Array ( [0] =>...

 
9:05 AM
0
Q: Hide c_box when no input

Mike Santi want if there is no input such as http://bloxhotel.nl/video?watch=YxIiPLVR6NA That a box will not pop up <?php ob_start(); include 'includes/inc.bootstrap.php'; $page = Array('title' => ((isset($user)) ? $user->username : ''), 'onload' => ((isset($_GET['utm_source']) && $_GET['utm_s...

0
Q: how to assign php variable to JS variable

HungryDB <html> <head> <script type="text/javascript"> var t; alert(t); </script> </head> <body> <?php $dbhost = 'localhost'; $dbuser = 'root'; $dbpass = 'pass'; $t_id = 6; $con = new PDO("mysql:host=$dbhost;dbname=testing",$dbuser,$dbpass); ...

0
Q: Create dynamic social network share Button

SimlofiMy goal is to create a social network share button on job seeker website. The idea is that jobs are published according to agent and the job ids, so i will like to share this job on social network. Example Share button <a href="https://twitter.com/intent/tweet?source=webclient&text=<?php echo...

2
Q: Checking user visits | PHP

DeadpoolOk so I store the User ID and a PHP Timestamp on a db. What I want to do is check whether the user has visited on a daily basis. Something very similar to SO's visited system. I know that I should have the user's visit record. But what I can't imagine right now is how do I determine the days tha...

0
Q: facebook php signed request and oauth redirection for mobile web

ChrisI have an issue with redirection uris, signed requests and mobile web facebook apps and I just cant pin point where I am screwing this up. I have a canvas app at xxx.com running an app that uses signed request to grab its users data. I decided to launch a mobile version so that my mobile users c...

0
Q: Doctrine 2 + Zend Framework 2 creating nested forms from annotations

user999305I am trying to rapidly create an admin panel for my application which uses Doctrine 2 and Zend framwork 2. I am using Zend framework's form annotations to create forms from my entities. This works perfectly for simple entities and for entities with a ManyToX relationship (using DoctrineModule Obj...

0
Q: PHP email sending issue with validated fields

Muhammad II am facing an issue, I have successfully validated the input and required fields in my form. But if the user Submits the form, no matter if the fields are empty; it shows the error message with fields but also send the empty email. I believe there is just a simple tweek need to be done. But I a...

0
Q: Return data back to ajax call in jquery

user2933671I have a php code (no functions, just direct code) which queries a data base stores values in an array and returns the array <?php //Query the database and fetch some results $array["min_date"] = $arr['min(date)']; $array["max_date"] = $arr['max(date)']; $array['query'] = $query; ...

0
Q: Add or Delete Textbox and get their value PHP Jquery

Cary Bondocwill you help me about this problem. What I want to do is to allow the users to have their choice whether to add more text box when filing their data. So far I have this code, I've been researching on this for a week. http://code.jquery.com/jquery-1.5.1.js This is the code that I got. <!DOCTYP...

0
Q: Jquery mobile checkbox in dialog does not work on mobile devices

user1906995I have a dialog window like so: <div data-role="dialog" class="windowsrestrictions" id="windowsrestrictions<?php echo ($i+1); ?>" data-close-btn="none"> <div data-role="header"> <h1>Windows Kısıtlamaları</h1> </div><!-- /header --> <div data-role="content"> <p> <form> <fie...

0
Q: Re-directing header() exit() fails

user2819164I am trying to automatically redirect users back to the index page of my website. The code worked fine in XAMPP, but when I uploaded it to my server nothing happened, not even errors. I also switched http://example.nl/ into index.php without any result. header('Location: http://www.example.nl/')...

0
Q: Namespace constants and use as

GordonMI'm having some problems with using constants from a namespace. If I define the constant and try to use as it, PHP seems unable to find it. For example, in my file with the constants I have code along the lines of the following: namespace \my\namespace\for\constants; const DS = DIRECTORY_SEP...

0
Q: csv file upload and update mysql db

IndraI am very to new to php. i am using the following code to open a csv file and update my database. i need to check the value of first row-first column of the csv file. if it is matching "some text 1", then i need to run code1, if it is "some text 2", run code2, else code3. I can use if else condit...

0
Q: SELECT GROUP BY latest entry in INBOX msg sent by user

Mohatir Si am building a simple PM for my personal website where a user can join and send message to the registered users on my website, i am stuck in grouping and selecting latest user (by latest msg time) in INBOX page my table : id msg_from msg_to msg date in_del out_del i want to show...

0
Q: PHP | Online Notepad

user2947423Hello, i recently made a Chat "application" in Visual Basic using PHP. I used this code: <?php $msg = $_GET['w']; $logfile= 'Chats.php'; $fp = fopen($logfile, "a"); fwrite($fp, $msg); fclose($fp); ?> I'm now trying to make a Online Notepad. What i want to do is in Visual Basic create a un...

0
Q: Both sql LAST_INSERT_ID() and PHP insert_id return 0

jakubplusI've been searching google a lot for this issue and really found nothing. People just keep copying MySQL documentation on last_insert_id and nothing else. I've got an issue regarding last_insert_id, because for both situations (php & sql) it returns 0. YES: I've set a PRIMARY & UNIQUE field wit...

0
Q: How to do Squid Authentication using php

ElatedHow to do the squid authentication using squid3. I am currently using ubuntu server 12.04. The server is configured as a transparent proxy server. Thanks in advance

 
9:59 AM
0
Q: Prestashop - media files don't load (403 error)

MalyoI'm currently learning Prestashop. I ran into first obstacle, after installing Prestashop, the default shop theme files don't load. Any ideas? Thanks in advance.

0
Q: Kohana - Using ORM

KevinHIḿ loving this website, kinda learned a lot here with those earlier before asked questions! Now i'm back, now with the Kohana Framework. I'm trying to learn a bit more about some frameworks, but i really don't understand the use of ORM and retrieve it in the template.. I have this code (contr...

0
Q: upload_max_filesize php.ini doesn't work

user2624687I have Debian-64bit-6.0.3 IspCP established on my cloud server.I looked at directory of php.ini file using phpinfo(); function then i went into this file via ssh connection(putty) and edited it as "upload_max_filesize = 10M",restarted mysql,even restarted server and then checked phpinfo(); again ...

0
Q: Magento add to card button

user2947466check this link here, if you choose the size -> Manufacturer's Suggested Retail Price $69.00 will flies off and add to card button (don't work) Can you help with it? I think this is some problem with Jquery conflict? How i can solve this problem? p.s. sry for my english it started with the fact...

0
Q: How to get data betwen <span ...</span> using preg match all?

user1788736i am trying to get data between two <span...</span> that has specific color #ff0000 using the following code but i getting no data! could any one tell me what i am doing wrong ? example of data: <span style="color: #ff0000;">get this text1</span> | <span style="color: #ff0000;">get this text2</...

0
Q: Uncaught exception 'PDOException' message 'invalid data source name'

GeekGirlI´m trying to connect to my database with PDO and show some blogposts on a page. However I´m getting this error message: Fatal error: Uncaught exception 'PDOException' with message 'invalid data source name' in index.php on line 61... I´ve been searching for help but really can´t figure ...

 
10:23 AM
0
Q: Show grid lines using PHPExcel

Raji A CGrid lines are not showing up .Below is my code.Please Help. <?php require_once '../Classes/PHPExcel.php'; $inputFileName = 'current.xlsx'; $inputFileType = PHPExcel_IOFactory::identify($inputFileName); $objReader = PHPExcel_IOFactory::createReader($inputFileType); $objPHPExcel = $objRea...

0
Q: Example event in yii

Michel PhelpsIt is very difficult to understand how to work with events in Yii.. Can help an example of how bind handler and how to call a method on the object that calls this handler? Thanks.

0
Q: Tables in PHP Split By Month

user2635961I am trying to split rows of data I have pulled from a MySQL database into distinct months in a table So for example Month : April row of data row of data Month : May row of data row of data I have been trying to follow other examples on this website but cannot really understand it I am ...

-2
Q: Any online API to convert videos formats using php

AyyazIs there any online service or api that can quickly convert our videos into another video format and return it in the my php script as I don't know about ffmpeg so much. Please give me suggestions.

0
Q: Redirecting Html click to specific area of other page

Java Studenti am doing two simple news pages , Scenario is as i have posted news head line and its description on page news.html and there is a read more button , when user will click read more button it will take to a page news_detail.html , now what i want if user clicks on first news from news.html pa...

0
Q: wordpress content edits in function.php

Ahmed Rhumai have some problems in something first of all what i want to do is replacing the "," And "?" And "،" And "؟" And "." in my posts and pages content with " here will be . or , or ? etc" i made up those functions function Huemix_content_filter($content){ return preg_replace('/\?/', '<...

-1
Q: how to draw(write) text on an image from right to left?

returnHow to write text on image like bellow picture (from right to left) ? Note: It is about RTL side languages. Edit 1: look at this topic, imagecreatefrompng() + imagettftext() low quality text - how to anti alias

0
Q: Drupal custom login with a custom URL

user2834820Before I write a few questions I need to said that I tried to made a custom drupal login on a way which is described here: Custom login form in a Drupal 7 So, that means to override http://example.org/user login page. That doesn't work in my case because I can hide header & footer (because they ...

-1
Q: If select equals a value use next select?

Tom IronsI have been messing with this for a few days now and I have come to a dead end. I don't consider my self good at php coding. I have 4 "Select" elements and the names for them are "sub[1]" "sub[2]" "sub[3]" and "sub[4]". I have a jquery that displays the different one depending on the previous sel...

0
Q: CakePHP reaching cookies from the view files

tranteI need to reach my cookies from the view files. I'm aware that one can use CookieComponent inside a controller and pass cookie values to view files with set(). Visitors of our website has an options page. User's selections are saved to cookies. Up to now I was using CookieComponent and checking...

0
Q: How to create a custom theme options page in Wordpress?

AdrianI want to create a custom option theme page for my wordpress theme and i found this tutorial http://wp.tutsplus.com/tutorials/theme-development/create-a-settings-page-for-your-wordpress-theme/, but the problem is that it doesn't work, and i am afraid that is too outdated. I am using wordpress 3.7...

0
Q: Mock namespaced class with SimpleTest

VivendiI'm using SimpleTest to unit test my PHP classes. I added a custom base class which does a spl_autoload_register to autoload the classes i need. But now mocking becomes a problem. How can i mock the classes that are loaded through a namespace? This is basically what i have in my test class. <?...

0
Q: How to obtain error for functions stream_get_line and fgets?

MartyIXI have a code where I open a socket connection. From time to time it happens that fgets returns false. I would like to find out why it happens. Is there a function that would provide more details about last error on $handle? Something like preg_last_error, json_last_error, ... The same question ...

0
Q: Unable to use Propel 2 (Class not found)

sineverbaI'm tryng from several days to setup and use first Propel 1.6 and now 2.0. PHP version is 5.4.4-14+deb7u5 What I done: 0) Fresh LAMP with a folder "test" in /var/www 1) Composer.json with { "require": { "propel/propel": "2.0.*@dev" } } (also tried with the alpha indicated i...

0
Q: front-end development and back-end development, meet each other

oozicI'm the front-end guy, I use Grunt (cssmin, less compilation, uglify, livereload, image minify, watch, lint...) and I started working with a back-end guy that uses Symfony (twig templating, assetics for most of the task I do with Grunt...) We are using a sort of Model-View-ViewModel pattern (I'm...

1
Q: How to accept post parameters in php web services

HarshI m developing a web service in php and want to accept parameter via POST method.I m using below code to accept parameter but its not working please Help I m completely new to PHP web service using POST <?php include './database/question_db.php'; include './model/question.php'; if(isset($_POST[...

0
Q: Facebook Chat Php

FarkhadI have a code which sending a message to my facebook friend. But the message does not always reach the recipient. Is there a limit of messages per minute in facebook chat api?

0
Q: Load Jquery with dependencies inside a php function

MuhammadI wanted to ask how can I code a jquery with dependency inside a php function. <?php wp_enqueue_script( $handle, $src, $deps, $ver, $in_footer ); ?>

 
11:23 AM
0
Q: Use the site PHP sessions for the forum

Aurélien MaigretI would integrate a forum in my website (phpBB, vBulletin, ... whatever). But I would use the sessions of my website for the users (and so my users table). Do you know a forum CMS using a user class "generic" (and not a lot of code anywhere...) ? Like that, I extend just this class with my own c...

0
Q: Build new template in Wordpress

AlessioMTXI am using WordPress with default theme TwentyEleven, I've edited something and everything was ok. Now I want do another Template Template Name: Contact This template must be equals to the dafult template Sidebar Template <?php /** * Template Name: Sidebar Template * Description: A Pag...

0
Q: WP archive.php does not work

ChloéI have problem with my page http://velvetart.net When I want to see monthly archive (http://velvetart.net/2013/10/) design is totally upside-down :/ I thought, when archive.php file is missing, for archive is use index.php, but then, why is my archive messy? :( I try to upload archive.php, dat...

0
Q: PHP file is printing everything after echo command

Ed FordhamI'm trying to build my first website. I have a domain name and am building it on my laptop before uploading it to my host. The website is mostly focused around searching a database of family tree information. I have created a basic HTML file which seems to be working ok. I have a search button...

0
Q: updating a php function

shantanuoIs there any way to call a code snippet after every mysqli_query function is executed? There is before and after insert triggers in MySQL. I am looking for something similar in PHP. In the following example, I need to log all the warnings after every query automatically (i.e. without changing th...

0
Q: asynchronous request/response with jquery ajax and php

micheleI have a javascript file that call with $ajax a php script. $.ajax({ url : "myscript.php", success : function (data) { doSomething(); }, error : function (data) { doSomethingElse(); } }); My php script will print more output during the process, o...

0
Q: add badge to TbMenu in yiibooster

Araz Jafaripuri want to add extra static html tag in TbMenu in NavBar Like This : $this->widget('bootstrap.widgets.TbNavbar', array( 'type' => 'inverse', 'brand' => 'company', 'brandUrl' => Yii::app()->getHomeUrl(), 'collapse' => true, 'items' => array( array( 'class' => 'bootstrap.widgets.TbMenu'...

0
Q: Attendance system in Cakephp - saving multiple data into multiple models

Matthew BasterfieldI am trying to create a system whereby a authenticated user submits a form. This form contains a date field, a number of text fields, and a list of members (of a meeting) with checkboxes marking if they are present and a reason (if the checkbox is 0). The date field, user id and the text fields ...

0
Q: Reading an html from file and saving it back miss linebreaks

AlexandrosI am trying to read a bunch of "big" htmls file to clean some unwanted elements and save some space. The htmls were created with curl and are "readable" (with linebreaks and tabs). But when i am trying to read, clean some elements and saving again to new files... i only get 1 line files without a...

0
Q: Loop a single Wordpress blog post in another page template

Amar Sylais there a way to loop a post selected by ID in another post? I have a custom post type in wordpress, and want to get the title of another post selected by ID. Is this possible? Thanks.

0
Q: Installing Yii 2 demo application

mazraarai am trying to install yii 2 and to run the basic or advanced application. i have tried the steps given here Setting up preview of Yii2 to do this. the steps i followed, 1 - Installed the composer 2 - Use composer to install the app alongwith dependencies(Yii): php path/to/composer.phar create...

0
Q: codeigniter replace view with template draw

Ing. Michal HudakI have implemented http://www.raintpl.com/ template system to codeigniter. Now when I draw a page I use this code: Example: <?php if (!defined('BASEPATH')) exit('No direct script access allowed'); class Test extends CI_Controller { public function __construct() { parent::__constr...

0
Q: symfony 2 profiler memory usage show 0 mb

matterixI've just created a new project in Symfony 2 and in my profiler bar in app_dev.php it show that my application use 3.8 mb / 0.0 mb. In my php.ini file i set it up to 512 mb but symfony still show's 0mb. ini_get() show right value sow how can i change it in symfony to show googd values?

0
Q: Two-legged OAuth Yahoo PHP example

JuniorI try to make private API requests for Yahoo. I used the code below but it does not work. It always returns the message 'invalid sig'. Can you help me with a Two-legged OAuth Yahoo PHP example that works? Thank you very much. <?php // a super-stripped down 2-leg oauth server/client example //h...

0
Q: KnpMenuBuilder Menu with FontAwesome icons

user2178964I try to create a menu builder in php, to reproduce this code : <ul class="nav nav-pills"> <li class="first"><a title="Voir panier" href="{{ path('cs_web_homepage') }}"> <i class="fa fa-shopping-cart icon-large"></i> Voir Panier <

-1
Q: I need to use paypal with a website and have no idea where to start?

user2860240I already have an order form but I need to link it with paypal but I dont know where to start. At the minute the order information sends in an email. Will using it with paypal affect what already happens in the form??? I just need to be shown where to start? Thanks in advance!

0
Q: OpenTBS exceeding maximum execution time

PwnageAtPwnI've this massive array which, unfortunately, has to be processed by the OpenTBS class. I'd rather a smaller array and apparently so does OpenTBS as it is exceeding its maximum execution time. It can't be my query as I timed that at 2.3 seconds when I switched OpenTBS off and when I put it back o...

0
Q: Deleteing a record that is in an html table using php

PatchesZaI'm having a little bit of an issue figuring this one out. What I've done is i've created a table using a while loop that displays all my courses into an html table : <?php include_once "Includes/config.php"; function manCourse(){ $SQL = "SELECT cname FROM course"; $result = mysql_query...

0
Q: Symfony2 web/app_dev.php/ not showing any code

KonterIam totally new to Symfony2 and I am trying to follow a tutorial, on how to create the first Bundle and Pages. http://tutorial.symblog.co.uk/docs/configuration-and-templating.html Now I have the following issue that, if I go to http://localhost/web/app_dev.php/ Nothing shows up. I download...

-3
Q: How should I count all deleted rows IN PDO?

RiKo$db->beginTransaction(); $del = $db->prepare('DELETE FROM hesabat_filter WHERE model_id NOT IN (SELECT res_id FROM result)'); $del->execute(); $del = $db->prepare('DELETE FROM hesabat_istilik WHERE model_id NOT IN (SELECT res_id FROM result)'); $del->execute(); $del = $db->prepare('DELETE FROM he...

 
12:23 PM
0
Q: No Privileges.My all data bases automatically removed when i set privileges to some table. I am using wamp

Hussain ShahI am trying to create a new database in phpmyadmin i got error No Privileges.My all databases automatically removed when i remove privileges lastnight in the specfic table. Please tell me how can i restore my all databases and also create new one? I am using wamp server.Also Privileges tab not sh...

0
Q: How to access SQLite database on remote server? Some web service?

KamilI have small desktop application written in .NET 3.5, that stores some data. It's small amount of data (for now its 1 table and about 1000 records total). Now Im using csv files and I have separate "databases" for each client/computer in company. Now I need to store that data from all desktops o...

0
Q: Bootstrap - Display horizontal list of accounts

JavI'm trying to display a list of "linked account" (google, yahoo, fb, ...) in a user's account settings page. I thought of displaying it horizontally (because users rarely have more than 1 or 2 linked account). Each elements of this list would have: 1/ the provider's logo (as an image) and click...

0
Q: Trimming a mySQL table block by block according to row's rank

user2593485This might be a typical database problem but I was unable to solve it elegantly in mySQL. I am looking for the most efficient way to trim an awefully large mySQL table (think of 1 billion rows) on a weekly basis. The table structure is c1 CHAR(3) c2 CHAR(3) d DATE rank SMALLINT [10 other irrele...

-1
Q: recovery variables from form

user2213362I have a problem with this form. In particular, I can not retrieve the value of the radio button in this form that has control of the fields in jquery and then sending in php. Stile css: <style type="text/css"> body { font-family: Helvetica, Arial, sans-serif; } #container { padding: 20px; m...

0
Q: Centering my css3 menu of changing widths...?

runelynxI have a css menu which has a width of 400 for non-Admins... and a width of 500 for Admins. If I set the UL width to 500, the menu centers fine and nicely for Admins. But for non-admins, whose mneu is really only 400 wide... it's off-kilter. So I removed the width attribute from the UL to try a...

0
Q: PHP include statement echoes '$'

Lee YiyuanI have two PHP files running on my web server, a.php: <?php echo 'A'; include('b.php'); echo 'B'; ?> b.php: <?php function foo(){ return 0; } Upon sending a POST request to a.php from C#'s HttpWebRequest, the response I got is: A?B However, after removing include('b.ph...

0
Q: File upload no temp file or file size

KevinHI am asking to many questions in here lately, i am trying to fix a file upload form. But that upload form is a multiple file upload form. Now i know that you can do print_r($_FILES['images']) to get the array with the posted images, but we have six image upload fields. And the output when i u...

0
Q: Endless while loop

Niek BakermansI am trying to post some table rows into a database. I have created a while loop and it keeps posting my first HTML table row to the database. The desired behaviour is that every HTML table row is posted to the DB. <?PHP $con=mysqli_connect("localhost","root","","freoplanner"); // Check connecti...

0
Q: Amazon Advertising API - How to submit multiple requests in a single call using PHP and SOAP?

RafaSashiI try to run a search through the Amazon Advertising API using various search indexes such as Books, ForeignBooks and KindleStore. AWS doesn't allow to submit more than one SearchIndex parameters and I was wondering what is the best way to submit multiple ItemSearchRequests in a single SOAP call...

2
Q: SQL Injection via URL parameter

user1204121I just saw in my webstats that someone appended a lot of SQL code to one url parameter. The URLs look like this: http://www.example.com/page.php?id=672%3f%20and%28select%201%20from%28select%20count%28*%29%2cconcat%28%28select%20%28select%20concat%280x7e%2c0x27%2cunhex%28hex%28cast%28database%28%...

0
Q: PHP Compare dates and disable/enable button

LashaI have php small code which doesn't work and i dont know why... I think i did everything right way.. Now i only hope that you can help... And here comes a code :) Thanks :) $exp_date2 = $myrow["exp_date"]; $date2 = date("Y-m-d H:i:s"); if(strtotime($date2) > strtotime($exp_date2)) { echo '<...

0
Q: var_dump doesn't display object type variables

Domix24does Var_dump can show a correct object variable? exemple : $dom = new DOMDocument(); $dom->load("test.xml"); var_dump($dom->getElementsByTagName("testnode")->item(0)); why this ouput is : object(DOMElement)[6] this not ouput the whole object?

0
Q: php_mysqli.dll warning in Linux Server

KerryI have an application that requires MySQLi. My Server is running on CentOS 6.5 with WHM. I enabled MySQLi but still my Error_Log says Unable to load MySQLi the strange part of issue is how can DLL run is Linux Server? The same application running in other Server but unable to run in my Server. T...

0
Q: PhP MySQL - Efficient data storage

user1938314I'm making a website for my music association, and some PDF's should be visible to the users. Now, there are about 200 users, divided in 10 groups (where one user can be in multiple groups), and 30 instruments. Now for all musical pieces, the database should know what musical piece in which group...

0
Q: Wordpress - common fields for posts

acoderI added a new custom post in Wordpress and named it Products. In admin menu in Products I have two links - All Products and New Product. Everything works perfectly, each product has it's own permalink, fields and so on. Question: What shall I do to have a few editable fields to be common for al...

0
Q: WP taxonomy used with custom-post type breaks my statics pages permalinks

user2203299I'm having a hard time setuping my WP. My structure peramink is this one : game/taxonomy-slug/postname To do so, i use the plugin UltimateCMS. I've made my custom post type name "game" who's configured like this: rewrite : true, slug : game/%games%, width tront : true, feed : true, page : tr...

0
Q: JS/PHP: Is there any way to get image height without waiting for window to load first?

user1775598I've got an image and I want to fire a JS function - but it's dependant on the height of the image. Something like below: if($(".displayArea").find("img").height() > 500){ //Important function comes in... myFunction(); } The problem is I have to use $(window).load() to get the height...

0
Q: Background Process Query execute in PHP without Request from android app

Mitul ShahSorry friends May be my question is silly but, I'm creating webservice for android app in Core PHP with MySql. I want to check continuously is any data available on near current time. I haven't any idea about this how to get data as a background process. How to execute query without any request...

0
Q: Curl error trying to send SOAP request

user2947742I'm trying to consumea web service with SOAP + cUrl library. This is the soap client script. <?php class soap_client{ public $xmlRequest; public $header; function set_header(){ $this->header = array( "POST /cntravelws.asmx HTTP/1.1", "Host: dem...

0
Q: PHP - Set Session Directory For Multiple Logins?

ArianaI have a login system for /site, and /site/site-admin. My issue as of now is if I sign in on /site, /site/admin thinks you signed in as an admin (obviously not true) I can't find any information on how to set the session only allowed to a directory, I've only found where to store the session data.

0
Q: PHP echoing an Array and splitting it up

BeardyI'm currently getting dates from a web page by using the following foreach($returned_content->find('div.box-inset') as $article) { $item['dates'] = $article->find('div.important-dates', 0)->plaintext; $articles[] = $item; } var_dump($articles); Which will output the following array(...

0
Q: where is a symfony bundle's base root saved?

user2516457I have a working symfony2 bundle on my computer (in the wamp/www/symfony folder). when I try to move it to a different computer, I get an error trying to get to it saying that filesystem.php can't find my index.php.twig - the thing is it's looking for it in the original path (the one in the 1st ...

1
Q: Is there some new way for tracking emails, instead of 1x1px gif, since now emails with it are disarmed?

tanjaI implement the script that is sending 1x1px gif but every email i send gets disarm. I read that now email clients know about this way of tracking and they disarm message with this.Does anybody use any other way?

0
Q: How to update a column of a table depending on the other column automatically in MySQL?

nkpIn my table, in one hour, 50 students will submit their marks in some exam everyday. Following is the table ID StudID Marks Rank 1 101 56 2 102 23 3 103 84 4 104 96 5 105 44 I want when all these records are inserted, after that, the rank should ...

0
Q: Break table if height is greater than value

Rawrrr1337I'm working on a script that generates a PHP table containing some values from a MySQL database. The script will be displayed on a TV, so I need to break it if its height is greater than 1280 (i've got this value by completing it with values 'till it fits perfect, then I've used jQuery alert to d...

0
Q: mysql_fetch_object(): supplied argument is not a valid MySQL result resource in C:\xampp\htdocs\ATP\test.php on line 27

user2947783When i try thic code i'm getting these two errors they are, 1. Warning: mysql_fetch_object(): supplied argument is not a valid MySQL result resource in C:\xampp\htdocs\ATP\test.php on line 27 Notice: Undefined index: Submit in C:\xampp\htdocs\ATP\test.php on line 48 num_rows; echo $count; //s...

0
Q: Uncomment extension=php_openssl.dll in a free host?

user2917204so I have a PHP script that needs OpenSSL, I enabled OpenSSL in localhost and it's perfectly working, I uploaded it to my web host and it's not working because it's not enabled! And I don't have access to php.ini, I'm using 000webhost, can you please give me another way to enable it? It just need...

 
1:42 PM
0
Q: Dynamically update progressbar yiiframework

York KeijzerHe there! I have function that calculates a percentage, these percentage is based on time. There is a start time ( for example 15:00) and an endtime (for example 15:05). If I call this function on 15:02, the outcome would be 40%. public function getBuildPercentage(){ $currentT...

0
Q: Apache not start on xamp control panel

Anna Dino When i start Apache on my xamp control panel i get this eror in eror log: Eror: [Sat Nov 02 01:47:42.699987 2013] [mpm_winnt:notice] [pid 5860:tid 228] AH00428: Parent: child process 5848 exited with status 1073807364 -- Restarting. I was google it and search the same problems on stackow, and ...

0
Q: WordPress adding category base to permalinks?

dbeI spent countless hours to resolve this without an result, so I'm asking community to help me. I needed to set an WP site to serve as FAQ site (I know, I know) with few single pages Posts serve as answers. So this is what I have done so far: Set up a single "support" page that shows category ti...

0
Q: Cake PHP Where Clause

user2673735I am trying to learn CakePHP and I have a simple question, I have $this->set('settings', $this->Setting->find('all')); in a Controller. I want to concentrate this down to: find all settings where the type is equal to General How could I do this?

0
Q: json array not getting created

bhagyashreeI think using following code jsonarray is not getting crated. Because I debug the code but it seems to be not getting in for loop. I have provide php code and part of android code. Please help me. I have written following code in onPostExecute if (success == 1) { // Getting A...

0
Q: mysql_query check for value range multiple times

Matthias MüllerI need to check for value range multiple times, this is how i do it till now: <?php mysql_query("SELECT preis FROM outfits WHERE aktiv = 'ja' and preis <= 100 $marke $farbe"); if(mysql_num_rows($preischeck0bis100) > 0) { echo "0 - 100 is there"; } ?> <?php mysql_query("SELECT preis FROM out...

0
Q: php, xampp total beginner in programming

MalikaI apologize beforehand if my question seems very dumb and annoying, but i'm hopeful i can find an answer here. I have no programming background whatsoever, and trying to learn php. I followed instructions and succefully installed xampp, and then started typing some short codes with tags using te...

0
Q: newer php version and loading lang files issue

user2783193I'm using tinymce html editor with imagemanager and filemanager plugin together with php. Everything works fine on server where is php verstion 5.2.17 is installed. On server where is PHP version 5.4.21 installed i have problem with displaying imagemanager window, on popup window (imagemanager)...

0
Q: Eloquent where owner equals follow

Sam PetterssonI am trying to make a twitter like feed in an application, I have a database called connections where inside there's user and follow and another database called feed containing owner which would equal to follow column in connections. What I could do if had every id of a follower statically is to...

-1
Q: isset function in php

user2944454everyone. I'm a newbie at PHP here. Please help me. i was wondering if it 'is possible to get two isset function to work in 1 php file?' and if not how to combine two isset function into one? is there a simpler way to validate both recaptcha and the activation code in db? much thanks if anyone c...

0
Q: How to delete list of categories?

Chloémy last question on my website http://velvetart.net. When I´m seeing single.php (http://velvetart.net/2013/11/new-onliner-shakira-online-net/) categories are here messy. When I check HTML, it showing that categories are in unordered list. <ul class="post-categories"> <li><a href="http://velvetar...

0
Q: htaccess allow default page

Jan De LaetHaving a problem with my htaccess. I have this to secure all my documents: Order Deny,Allow Deny from all Allow from 127.0.0.1 <FilesMatch "\.(htm|html|css|js|php)$"> Order Allow,Deny Allow from all Allow from 127.0.0.1 </FilesMatch> Now everything works fine, but only my default page www.mys...

0
Q: How to make a small website multilingual?

ColoneljesusI have this really tiny (static) site, that is basically just my online business card and I want to have it in English and German. I detect the browser language and also let the user chose manually; so I have the right $lang variable ready. My question is how are the multiple languages best impl...

0
Q: Displays the contents in each categories

Joemar AlfecheHmmm.. I already display the categories but now, how am I suppose to display the contents of each categories everytime I clicked them.. Here's my codes for displaying the categories <?php $connect = mysql_connect("localhost","root","") or die ("Couldn't connect to database!"); mysql_select_db(...

0
Q: Add details from email_activation db to member db after email code and captcha activation

VinsonHow can we add all details in email_activation db to member db at check activation script.php?Move the details in sql database. <?php require_once('recaptchalib.php'); $privatekey = "your_private_key"; $resp = recaptcha_check_answer ($privatekey, $_SERVER["REMOTE_ADDR"], $_POST["recaptcha_c...

0
Q: Logic to schedule appointments based on location

MxAgentI need a simple solution to schedule appointments in a specific geographic area based on their locations. For example: I've got 10 customers to visit in the area of Berlin and 20 to visit in the area of Frankfurt. Every customer has a detailed location (eg. Street, Postcode, City, etc.) The...

0
Q: Save values of input fields in wordpress 3.7.1

AdrianI have the following custom settings theme page: <?php function setup_theme_admin_menus() { add_menu_page('Theme settings', 'Theme Options', 'manage_options', 'cleanmean_theme_settings', 'theme_settings_page'); add_submenu_page('cleanmean_theme_settings', 'Social Settings', ...

0
Q: Php re-submitting url change one variable

Masood HosseiniI have a php page that displays data using different variables submitted through the url. For instance: index.php?rownum=30&colnum=2&qlang=en I need to give the user the ability to change the sort order. For that I have added an html select with two options calling the re_order() function whic...

-2
Q: converting phone numbers to vcf format algorithm

user2849437From: BOBBY,9238123 LOBBY,2312312 Into: BEGIN:VCARD VERSION:2.1 N:BOBBY;;;; FN:BOBBY TEL;CELL:9238123 END:VCARD BEGIN:VCARD VERSION:2.1 N:LOBBY;;;; FN:LOBBY TEL;CELL:3423423 END:VCARD the bobby repeats twice and phone number once This is what I have tried my code: foreach(explode("\n", $...

0
Q: PHP - Only variables can be passed by reference

user2693017$v1['ip'] = $url; . why isn´t the following working ? $sock = @stream_socket_client('tcp://'.$v1['ip'].':25565'. $errno, $errstr, 1); but this: $sock = @stream_socket_client('tcp://'.$v1['ip'].':25565'. $errno, $errstr); and this: $sock = @stream_socket_client('tcp://'.$url.':'.$port, $...

0
Q: Woocommerce custom order for archive page

user1355748I'm trying to change the products order on archive-page.php in Woocommmerce. I wish to always show out of stock products at the very end of the page, no matter if products are sorted by date or by price... By default, I'm trying to show products sorted products by date, with out of stock produc...

 
2:54 PM
-2
Q: i got this codeigniter error when i run my project : Message: Illegal offset type in isset or empty

Ahmed Alii got this codeigniter error when i run my project : my page browser loaded with my view but at the top of my view i got this message : A PHP Error was encountered Severity: Warning Message: Illegal offset type in isset or empty Filename: libraries/Form_validation.php Line ...

0
Q: PHP change folder owner to apache

arbitterSo I created a couple of directories and files with FTP, thus the owner is the username I use to login to the server. Now I'd like to allow users of the website to upload images to those directories. Unfortunately for the website to store images, it should be owned by Apache. How can I fix this? ...

0
Q: Wordpress compatible slider with HTML content in thumbnails

AdrianI am just wondering if anybody knows of either a wordpress plugin or a stand alone slider that allows html content as thumbnails. What I mean is that if you take a look here: http://tinyurl.com/pdfu3nn The jockey on the horse would be the slider image and then the little boxes at the bottom of ...

0
Q: converting jquery request to ajax request

KarimkhanI have call using jquery: rate=$('#rateit99').rateit('value'); That I want to perform using ajax. How could I do? rateut99 is the ID of element from where value is coming. Trying to solve this problem: Loading php file with ajax call and performing button click event

-1
Q: Curl 400 error when call yahoo search result

user2944926I am scraping yahoo search results .i got yahoo search form action yahoo search result but when i call using curl its give 400 error why? but this url in web browser working fine. please help me.

0
Q: Regular expression to detect Internet Explorer 11

benI am using this preg_match string preg_match('/Trident/7.0; rv:11.0/',$_SERVER["HTTP_USER_AGENT"] to detect IE11 so I can enable tablet mode for it. However it returns "unknown delimiter 7". How can I do this without PHP complaining at me?

-1
Q: Codeigniter search bar

XeganoWhen you type something in the search bar and press the button I want it to be added to the url. For that I sent the POST in $data['q'] to the view. And did this in the view. <?php echo form_open('dashboard/'.$q); ?> But when I click the button nothing happens. The second time I click it it do...

0
Q: How to parse XML results with multiple pages

user2947931I'm hacking away at an API from which I'm parsing XML results files with PHP. Each XML result page displays 50 results max after the initial query. To see additional results, at 50 results per page, you must append ?pagenum=2, ?pagenum=3, and so on to the XML file URL. So, my question is, how do...

0
Q: Auto set view in Laravel

RobI want to automatically set the view on a GET request in Laravel. In the BaseController constructor I do this: if (Request::server('REQUEST_METHOD') === 'GET') { $action = explode('@', Route::currentRouteAction()); $view = explode('get', $action[1]); $view = strtolower(end($view)); ...

-1
Q: simple html dom parser or a regular expression

user2947922There is a html page, it contains a block: <table class="tborder" cellpadding="6" cellspacing="1" border="0" width="100%" align="center"> <tr> <td class="tcat" colspan="2"> Some regular text <span class="normal">the desired text 1</span> </td> </tr> <tr> <td class="alt1" colspan="2"> <span class...

0
Q: I need to connect my form to a database (I think)

dsheshI have a conenct.php file that has $server, $user, $pass, $db It seems like its trying to connect to a sql server.$conn They also provided FTP information for me. (I'm not sure how I have to use this) The instructions are to create a website from an illustrator file they created (which I have ...

0
Q: Php Load Wallpaper By Title Not By ID

Bogdan Crișuhellow everybody my name is crisu bogdan and i have a problem, how can i make my php script load the images by title and not by id. I want to do this so my url should be htt://picxeto.com/wallpapers/"wallpaper title" not http://picxeto.com/wallpapers/"wallpaper id" Please can somebody help me ...

0
Q: get return value from php for ajax call

MikeI am trying to get the auto increment id from a database insert in php back to my javascript ajax call: My ajax call looks like this: //get values var note = $('#note1').val(); alert(userID); alert(beerID); var ajaxSettings = { type: "POST", ur...

0
Q: Sending mail with PHPMailer using Google's mailservers fails

erdomesterI am using Google's mail servers to send emails. For email sending I am using PHPMailer. This is the snippet I am using on my example.com/contactus site: $mail = new PHPMailer(); $mail->IsSMTP(); $mail->SMTPDebug = 2; $mail->SMTPAuth = true; ...

 
3:06 PM
0
Q: PHP Array - Remove unwated key + retain data

MrYanDaoHow do I exactly remove an unwanted parent from an xml node and keep the data intact? Something like array shift. For example, I have an array [LineItems] => Array ( [0] => Array ( [LineItem] => A...

-1
Q: PHP - AJAX AND MYSQL for Checkbox filter function

user2947950is there anyway to turn this : http://www.w3schools.com/php/php_ajax_database.asp into a checkbox filter function? like those commercial shopping website with filter [] Red [] Blue [X] Black

0
Q: html href not linking to correct function

user1532468I have a menu which is in header.php which is called as an include on each page I load. What is happening, is if I click a link in the header which has an absolute path, when I go the link and load the header.php I try to call an onclick() which used '#' as a href, but for some reason inherits th...

0
Q: php mysqli looping too many results

user2370717I'm having a little issue with looping through my database retrieving results, I understand why I am getting the issue but not too sure on how to implement the solution as my PHP is not the greatest. I have looked through the forums but couldn't find anything to address my problem. From below m...

0
Q: Warning: Invalid argument supplied for foreach()

Alex.DXi have this MySQL database for news categories: id - name - parent 1: now I need to list parent/child categories into <optgroup><optgroup>. PHP CODE: $options = array(); $categories = mysql_query(" SELECT id, name, p.name AS parent FROM " . CATS . " AS child INNER JOIN ...

0
Q: Sessions variables not available on ther pages.

user2944805I really don't know what I'm doing wrong here. Session variables from page one are not available at page 2. Notes: Page1 and page two are not in the same folder. Page 1. <?php session_start(); $_SESSION['TestSession'] = 'Available'; ?> Page 2. <?php session_start(); echo "Your se...

0
Q: PHP GD library returns broken image

Onur GökerMy problem is that I can not create images using php library in Codeigniter. For example, I am using the sample code in php.net below: header("Content-Type: image/png"); $im = @imagecreate(110, 20) or die("Cannot Initialize new GD image stream"); $background_color = imagecolorallocate($im, 0...

0
Q: PHP Table Split By Month

user2635961I have been trying to group the output from my database into time periods. For example 2013 May Some Data More Data 2013 June Some Data Some Data The code below works to an extent but will only put one row of data against each month even though there should be more. ie each month has more...

0
Q: INSERT INTO error php

Christian HilberinkMy code doesnt work so can someone please look at it? I setted up a MYSQL database called retroradio, a table called sollicitatie with fields id, name, rank, link, motivation and niewsartikel. i wanded to INSERT all of them but it didnt work so... <div class="contentbox"> ...

0
Q: I am making a script in php and need to show total views of links

user2947999I am making url shortner and got stuck into one thing. I want to add some codes that will show total shorten url and total of all visited urls. I got codes and its running cool in total shorten urls. But the thing is that I am not able to show total numbers of visited urls. I mean to say that I...

-3
Q: How would I make this query return all rows with the id of 1?

user2930229Okay, so excuse me if this is a silly question but I'm not all too familiar with MYSQL. Here we go: When you perform the following code: $result = mysqli_query($this->con, "SELECT * FROM blogfeed WHERE id = 1"); $result = mysqli_fetch_array($result); return $result; it returns an array with...

0
Q: php regular expression any word characters (\w) but numbers

user2909037I need to get everything from this regular expression except numbers, how can i do it ? ^[\w'-`´]{1,50}$

0
Q: PHP/SQL can't use data from query after while loop

user1209203$sql = mysql_query("SELECT * FROM table WHERE user='$user'" ); while($data=mysql_fetch_array($sql)){ echo $data['user']; //this is fine } echo $data['user']; $data=mysql_fetch_array($sql); echo $data['user']; The last two echos are empty?

 
3:42 PM
0
Q: Using Jquery autocomplete with images

Irene T.I am using the code bellow of foxycomplete to get some results from my db with images. With local files works great but i cant do it with mysql. Here is my code that i am using.. <form id="autocompleteForm" name="autocompleteForm" action="" method="post"> <input type="text" name="s" id="s" ...

0
Q: How to skip/mark incomplete entire test suite in PHPUnit?

Maciej SzDescription I have a TestSuite which I need to mark as skipped (the entire test suite - not the specific test cases within the suite). class AllTests { public static function suite() { // this does not work same as within TestCase: // throw new \PHPUnit_Framework_Ski...

0
Q: Duplicate key in array

AlmogHow i can print key exists ? Example: $List = array ( 'F1' => 'Boli', 'AE' => 'Joo', 'TR' => 'Yamm', 'AE' => 'Xss' ); The key 'AE' is exists, how i can check for duplicate key ? *And again, sorry for my bad engl...

-4
Q: How to read bigdata file which has 7G?

www.tonitech.com的站长I have a data file about 7G. It's to big for my computer to open! It is a file without postfix so that I can not identify what type of the data, but I guess it may be sql file. How can I open it with php programme?

0
Q: PHP - failed to open stream: No such file or directory in

Ty Tan LeeI am new to PHP and Objective-C, I have searched for the answer to this but everything seemed complicated and I could not understand. I am trying to upload an image file to my ftp server using PHP. I used this code in my app for the image upload: UIImage *myImage = [UIImage imageNamed:@"black_...

-1
Q: I need some tips on security PHP pages

Doron LeviI learn php, but I do not know much about security. The only things that i use them is just htmlspecialchars and mysql_real_escape_string, to check information that the member send. Except this, i do not know anything about security in PHP. Can you tell me some tips about security, or things t...

0
Q: Join without really joining

Sam PetterssonI am building a twitter like feed system and after a bit of searching around I found that I could with a check if the user follows the poster and get thoose posts with join. I query my database using Eloquent like this: $this->where('published', '=', '1')->join('connections', 'feed.owner', '=',...

0
Q: How to get a polygon from a postcode?

TabI am looking for a way to draw a polygon from a postcode or alternatively all postcode coordinates to draw the polygon. I searched for a long time but I have not found anything. Can someone help me? Thank you very much

0
Q: Prevent unfilled fields in html form being sent

user2948063Not a php programmer, just html for me. I am using a very large form with many text fields for quantity of items ordered. I mean hundreds. If you fill out one or two items (most would usually be around five) the form returns all results, with those chosen with answers, the rest are just blank,...

0
Q: Login System and Session using OAuth 2.0

Christopher FranciscoI am working on a web application which requires a Login system. Usually I would create the login process and the session handling by myself but this time I'm working on a bigger project and I want the session handling to be used with access tokens. I have read OAuth information page but I'm not ...

0
Q: .htaccess only one RewriteRule is not working

Dorian_gdI have a problem with only one page on the RewriteRule htaccess: the page http://www.snes-fr.net/staff.html is not working (404) but ALL other are. staff.php is in the folder: http://www.snes-fr.net/pages/staff.php .htaccess line: RewriteRule ^staff\.html$ index.php?page=staff [L] but this li...

0
Q: How can i create a pop up box with two links like "quit" and "back";

user2779363Iam creating a multiple choice question paper, how can i create a pop up box when a user decides to quit exam, for him to quit or back with question paper? I am totally a beginner, Thankfull to any help...

-2
Q: Searching for an aternative to Atk-framework?

Houcine Cherifis there any alternative php framework that can be considered as a successor of the atk-framework, it seems that the akt-framework is not supported any more.

-1
Q: How to count rows in mysqli?

Tim ChapmanI know this is PHP 101 but I've only found the answer using MySQL. I would like to know the most effective way to do this. How do I output in PHP a mysqli count as query? The query is $result = mysqli_query($db_conx,'SELECT COUNT(listing.id) as total FROM listing INNER JOIN users ON listing.us...

0
Q: how extract data inputted using form and display it using php in table

bessan al bessaniI am not sure how to go about doing this, but I have an assignment tomorrow and i'm new in php i have to put in the html part a text box and check bob and radio button and drop down list and then take data from user and then extract data in php and display it in table also using php . Any one ca...

0
Q: Proper PHPDoc for switch statement with object return value

wtfzdotnetIf you could be so kind to take a look at the private project I'm working on at this line ( the function api() ). https://github.com/wtfzdotnet/php-tmdb-api/blob/develop/lib/Tmdb/Client.php#L79 What is the correct way here for IDE's to actually auto complete the methods of the returned object i...

0
Q: How to add select2 extension as filter in CGridView on Yii

Yovany AI'm trying to add in one column of the CGridView a filter with select2 extension following this answer but does not work. My code: In view vehiculos/admin.php <?php $this->widget('zii.widgets.grid.CGridView', array( 'id'=>'vehiculos-grid', 'dataProvider'=>$model->search(), 'filter'=>$model, '...

0
Q: PHP socket bind/listen are not working when used in method (class)

GlisterI wanted to implement a simple locking mechanism for few cron jobs and decided to do it in unusual way. It looks like PHP is a bit buggy when it comes to socket create/bind/listen. A code that is working: <?php echo 'EXECUTING: '. __METHOD__ . \PHP_EOL; if(false === ($socket = \socket_create(\...

0
Q: What is the XML feed for search engine?

artur99I've searched a few days but i could'n find the right answer and complete answer. I would like to know what is it, and how to integrate it on my website. Thank you!

0
Q: html textarea mysql insert keep new lines for HTML and android

MikeI have a mysql database in which user can insert a paragraph or two of text. If they click enter in either the wen entry or android entry I would like to keep that new line when I display the text on my website and in my android app. My php for inserting into the db is: <?php error_log("startin...

 
4:24 PM
0
Q: Javascript submit to mysql replay will replace div

Zara Rebecka Elisabeth ZentioAm trying to send data to a MYSQL php script i have (that works) and that script "echo" back what ever i want. The Script php file is fully working and i can select what to echo back on succes. But now i want to try switch from HTML to Javascript to replace a div without pageload. Maybe the scr...

0
Q: Save values of input fields in wordpress

AdrianI have made the following wordpress theme settings admin page. <?php function setup_theme_admin_menus() { add_menu_page('Theme settings', 'Theme Options', 'manage_options', 'cleanmean_theme_settings', 'theme_settings_page'); add_submenu_page('cleanmean_theme_settings', 'Soc...

0
Q: Select value from database with php where condition value is similar to input

SpiderLinkedI was wondering....is it possible to retrieve a value from a mysql database if the value of the WHERE statement is similar to the input text? Something like the similar_text() function but applied to the search condition. Example: <?php $res = mysqli_query(*CONECTION*,"SELECT value FROM t...

0
Q: Combine 2 or more nested arrays which are all within one parent array object

JoshcI am creating a basic foreach loop gallery function, but this gallery function I am trying to make is a little different because I am merging all the gallery images into one. And there are multiple gallery arrays that I need to combine into one, however these gallery arrays are contained in one ...

 
4:42 PM
0
Q: Need help in figuring out and to test a possible security risk

Sither JohnaIve been trying to make a news posting function, im worrisome as to weather the security is tight enough, i wanna allow as much raw code as possible in the news posts, however i dont want my news writers to be printing the whole database and abusing it in any way.. I have the following, which is ...

0
Q: Integrating Google Analytics OAuth with multiple client domains

jdawgI've written a service which runs on the clients own domain, but we retain the access to the source code. One of the features I am hoping to implement is the ability to view your Google Analytics within the backend of the system, and I have written a script with uses Google's OAuth to authenticat...

0
Q: Get all variations of multidimensional array

KudosI have an array, for example: Array ( [2] => Array ( [3] => Yes [4] => No ) [4] => Array ( [28] => Maroon [29] => Red [30] => Dark Blue [31] => Grey [32] => Pastel Blue ...

0
Q: What is this design pattern called?

user2948190I'm learning design patterns and I came across this code on Github. What is this design pattern called? <?php class User { private $_id = null; public function __construct($id = null) { if (is_null($id)) $id = Session::get('user_id'); $this->_id = $id; ...

0
Q: Pull data from privately pushed Google Drive file

nathanaelphilipI’m trying to pull a spreadsheet that’s been privately published. Is this even possible? I am currently using the Google Drive API to pull information from the spreadsheet, but it’s a dynamic sheet that requires the user to have the spreadsheet opened in a browser tab. The client has over 200 s...

0
Q: How to echo a $_GET safely?

Merijn Den Houting<?php echo $_GET['id']; ?> Doesn't look very safe to me.. What is our best option to show an GET element? Something like a preg_replace on all the special characters, or htmlspecialchars?

0
Q: Check javaScript variables inside of an Ajax

arajI have an Ajax code setInterval(function(){ $.ajax({ type: 'post', url: 'php/internetSpeed.php', success: function(data){ if(data.msec < 1){ if(data.ksec >= 512){ $('.intr').attr('src', 'imag...

0
Q: How do I instantiate require.js modules on different pages, partials with codeigniter?

Cameron StrandbergI'm trying to update the javascript on a large scale, php/codeigniter based website. It has many, many php partials for code being loaded onto certain pages, but only one footer, header. Most of the partials have inline script tags in them for loading javascript. This needs to be fixed and becaus...

0
Q: Styling a code block with CSS

cantsayI'm writing a tutorial for my blog, and I'm using [code][/code] tags around the text I want to be displayed as code. I've tried replacing [code] with <code>, <pre> or <div class="code-block"> However, with <code></code> if I indent some lines with spaces the spaces don't show up, so it's not as ...

0
Q: Making a php mail function send to everyone in database but 1 person every minute

user1974751I have a database of users with their emails but as my hosting provider doesn't allow mass emails I was wondering if there is a way so that I can send the same email to everyone in the database but 1 person ever 1 minute. So that It sends to person '1' and waits one minute then sends to person '2...

0
Q: Sending an email with serveral attachments in UNIX after reading the contents of a directory

user2945682I am trying to put together a shell script which reads a file with 3 lines such a *.mail file, the first line contains an email address, the second line the name of a *.txt file and the third line the name of a *.xml. The script should look in a directory and read the *.email file first. There ...

0
Q: Exec Tar Function not implemented error

user2945583exec('Tar -zcvf ddat.tg uploads 2>&1', $output); var_dump($output); $valarray(2) { [0]=> string(57) "Tar: Nie mogę rozwidlić procesu(could not split? the process): Function not implemented" [1]=> string(42) "Tar: Error is not recoverable: exiting now" } This is the error im getting. I adde...

0
Q: double cache system php

Joe GI have a code that goes like this: if such cache exist with timestamp less than 2 days, then show cache file and break. Else create file and cache it. What I would like to do is if the cache file exist less than 2 days, then show the cache file, and create a newer cache file. So, that next user ...

0
Q: Shapefile (.shp) conversion to other formats

Brandon SchmidtI have searched extensively all over Google but I haven't really found anything of meaning; are there any online services or programs to download that allow .shp files to be loaded and exported to formats such as .csv, .txt, .kml, or any other formats that are human readable? In addition, php and...

0
Q: How doesnt my php code connect to the database..using Xampp

Darius First forgive me if the code is not in an organized manner, I have tried to insert code in a neat manner but by the time I fix it, the system times out, so I cant post and have to do it all over again..so this time I am not going to adjust the code.. just copy past it into forum I created a from...

0
Q: MySQL Create Table from Query

xur17I have a large table with what are essentially log entries. For most of my queries, I need a table with the most recent entries, so I created a 'view' from the following query: SELECT t1.store_id, t1.code_id, t1.working, t1.expiration, t1.details, t1.price FROM code_stores t1 LEFT OUTER ...

0
Q: file_put_content save in several files, limit by rows

user2568578Instead of saving all the lines in 1 file (using file_put_content), I want to save several files, each file contains a certain number of rows. As file1.txt file2.txt i have this code: $file = foreach($rows as $row) { $row['domain'] } file_put_contents("file.tx...

0
Q: PHP phone pattern validation error

Pataki ZsoltI have an inc file (test_form4.inc) which defines the form that collects a user's name and phone number. <!doctype html> <?php /* Program name: form_test4.inc * Description: Defines a form that collects a user's * name and phone number. */ $labels = array( "first_name" =>...

0
Q: No other transition works except Fade, nivoSlider

Rohit SmithThere are no effects working on the nivoSlider except fade. Check out their official site: http://demo.dev7studios.com/nivo-slider/demo-3/ It says: Nivo Slider with Dark Theme & Random Settings But, the only effect seen is Fade. Is anyone aware of this issue?

0
Q: How do you create token based authentication in php

user2216093I have managed to do HTTP basic, But I want token based authentication so that the user can delete or add resource, how do I do this in PHP, what code do I need to write Also, what do I need to do if I want admin to access some resource which I don't want a normal user to access?

-1
Q: ideas to Generate serial number

Danish FayazOkay Guys so its like this. I have made an online complaint application in PHP and MSSQL, which generates unique ticket numbers when a complaint is submited. Now the ticket numbers has to be 4 digit, starting from 0000. I've made an int datatype column and created a UNIQUE index on it as well. No...

 
5:42 PM
0
Q: Select row with the name of an operator php

SpiderLinkedWhile working on my project i have discovered the following problem. I have a row named: "desc" The problem is that this is the name of an SQL operator.. so i can't select it or use it in SQL statements. I tried using SELECT 'desc' FROM table WHERE .... in statements.. but is does ...

 
5:53 PM
0
Q: Checking if variable exists for child class

unskaI'm creating global setters and getters for my parent class since I don't want to create them for each child class variable (but I will occasionally overwrite the parent global setter / getter). I'm using __call with it and I'm parsing the method name like this: if (strtolower(substr($method, 0...

0
Q: how to import google fusion tables into mysql to draw a polygon on google map?

Tabhave this csv file and I wish to import it in my MySQL database to draw all polygons I want simply by typing a postcode. In this file I have the postcode a list of coordinates (my idea is to use all coordinates to draw an accurate polygon a field called 'area' (I have no idea how to use this i...

0
Q: Why is PHP throwing this parsing error?

NickersoftI have a small question for you all. I currently have my site on 000webhost, and the following line: $price = explode(".",$item->sellingStatus->currentPrice)[0]; causes the following error: Parse error: syntax error, unexpected '[' in /home/a1257018/public_html/scripts/myfile.php on l...

0
Q: Symfony2 - load a view from a view

eddard.starkI used to work with codeigniter. Now I am starting to learn Symfony2. I was just wondering, in codeigniter i could load a view from another view. Like, I could load menu.php from index.php. This is how I used to do it - //in index.php <?php $this->load->view('menu.php'); ?> Is it possible to ...

0
Q: Changed hosts, dropdowns and pictures don't work

myoloyeI've just changed website hosts but for some reason pics and articles I wrote don't seem to have carried over - how can I fix this? Thanks

 
6:13 PM
0
Q: PHP: get form's name

user2938377What a problem I'm new in php, and I faced a very trivial problem: how to get form's name in php? What I've tried: $name = $form['name']; print_r($name); // echo stuff like SimpleXMLElement Object ( [@attributes] => Array ( [name] => feedback [description] =>... Question: How can I get only...

0
Q: Symfony2 - How to make symfony2 smaller

eddard.starkI used to work with codeigniter. Now I am starting to learn Symfony2. I was just wondering is there any way to make the Symfony2 project a little bit smaller. Like, can I delete a couple of folders inside vendor. I am quite sure I am not using all of them. And if i do that, will it make the perfo...

0
Q: How to merge two xml arrays in a third array in php

BilalI have two xml arrays, and i want to merge these arrays in a third array... the first xml struxture is $current = '<forms id="frm16648"> <group ref="" id="tarascioheader" mode="block"> <label> <![CDATA[Group (tarascioheader)]]> </label> structure u <select ref="" id="petorresp">...

0
Q: Most occurred letter in a string using php function

simmi simmii have string AABBBCCCDABBAACBB , in this i need to find the most occurrence of Character , how can i find this?? in above string it should return 7 ad B comes 7 times i.e max. $str = "AABBBCCCABB"; $strArray = count_chars($str,1); foreach ($strArray as $key=>$value) { echo "The character <b

0
Q: Drupal Migration - Error 404's

flindersStationI've set up a Drupal 7 site locally and have ftp'd the site over to my ISP's server which is a linux box running PHP and MySQL. I've never successfully logged into the site before and I have locked myself out. When I go http://www.example.com/?q=user and click on request New Password then I get...

0
Q: Searching XML data in PHP

Cledson StefanatoHello everyone I know to do this search with MySQL using LIKE '"%% $ _POST [" txtbuscar "]%%"', I am now performing in XML. I need to come up with an input txtbuscar. The script below I have managed to list and page, and search for the most important word, but I believe that is something, but is...

0
Q: Twitter Search API v1.1 not working

Nick JonasI'm using the Twitter Search API v1.1 to simply search by hashtag #monstercareers. This bit of code works for other hashtags, but will not work for this particular one. I know this API is slightly different from the one Twitter actually uses (which makes it difficult to test), but if you search...

0
Q: Proxy server for WordPress is not working

user2948346I have created a proxy server like http://domain/blog and this proxy server is accessing a WordPress site which enabled our theme. The WordPress site is like http://blog.wordpress.com URL. Our WordPress site(http://blog.wordpress.com) works perfectly. But when we accessing the proxy URL(http://...

0
Q: Upload multiple images to server & saving product description, categories, etc & image path to server

Kat Marzan WilsonHi~ I'm a beginner so don't hold that against me. I have some basic knowledge when in comes to php/mysql & jquery so I can understand a bit but please explain it as simple as possible. Thank you very much in advance. I need a catalog script. I've looked everywhere but I can't seem to find the ri...

0
Q: imagettftext-How to insert a text exactly in the middle of a row in a template image

PasargadIn my web application users can enter a name and department name and they are supposed to be exactly in the center of a row in my template image: What I have tried: $text1 = $this->input->post("name"); $Length1 = strlen($text1); $x1 = 530 - ($Length1 * 14.8); $text2 = $this->input->post("dept"...

0
Q: I reinstalled WampServer, now it will not load php but the icon is green

Skylar BruceContext: I f** up and lost all access to root, and I forgot my password to the mysql cmd so I just uninstalled wamp and deleted the folder then reinstalled it, root worked perfectly after but then when I loaded index.php (default one) it showed the php code and did not run the php. So I thought ...

0
Q: set two values for an input name attribute

CodeLikeri have a check box list that some limited check boxes can be selected. for this i set the name attr of all them "answer" to work with the js function properly(i got the function from some where). <?php else if($result['type'] == "multipleChoice"){ echo' <div><input type="checkbox" name="answer...

0
Q: Using spl_autoload_register

user1889867Must I put the following lines in each PHP file I create to use autoloader? Or there is a solution to do it once, inside "index.php" of the application for example, and instantiate the classes in other files like usual? function autoload($class) { require('/path/to/mylibrary/' . str_replace...

0
Q: PHP Parse error: syntax error, unexpected end of file

user2948326I am very new to PHP and somehow got thrown into an advanced level course. My instructor will not offer any help since it is an advanced course. I will post my code below in hopes that someone can at least point me in the right direction for a fix. This is only the first part of the assignment, b...

0
Q: Min length for text area in my form

TerryI need to set a min length and a max length for my text area box on my website. I know for max i can do it in html, but min you cannot. Could someone help me with this? I can do if, else statements but that would be after the form is submitted. I want it to tell the user the length is too short b...

0
Q: PHP: pass variable to javascript method

user2938377What I have: Try to pass variable to javascript method in such way: $name = $form->attributes()->name; echo '<input type="radio" onclick="show('.$name.')">'.$form['description'].'<br />'; ... <script> function show(name) { //DEBUG HERE! ... } </script> What a problem: In browser's de...

0
Q: Wordpress Upload directory to external folder or site's parant folder . how to?

ZahidI am having an issue with wordpress upload folder... i don't know if it was discussed here before.... i am running three sites under one domain like 01.mydomain.com 02.mydomain.com 03.mydomain.com All these sites are having there own installation directories under the main domain like mydoma...

0
Q: MAC OS: How to call web service by POST METHOD

user2948373I'm studying Mac programming. I have a php File in my XAMPP, this File is use to insert data to my database. I want to use post method to call php File and execute sql string. Thanks so much!!! (Sorry I'm not good at English) my PHP file: <?php $DB_HostName = "localhost"; // ten host $DB_Name = ...

1
Q: Newbie to PHP. Parse error: syntax error, unexpected $end form_process.php on line 53

Rob HeselwoodI copied this from a link on a youtube video, and have changed a few things slightly to suite my needs. I have put the code in NETIDE and checked the number of bracing brackets on each if else statement, and they all count up the same. The line where the error is occurring is after the closing ?> <

0
Q: Dynamic div swapping using php/jquery resulting in a page recursion

SeRosiSI am working on making a dynamically loaded website using some php code to swap out content from various other files. While on top of that I am using jquery to beautify this swap out. Relevant PHP: <?php // Set the default name $page = 'home'; // Specify some disallowed paths $disallow...

0
Q: Log-in system errors

todaroaAs weird as this sounds for my Database Management Class I have to write a log-in system that stores the user's password for 90 days so that all they have to do is put in their username to login. Yes I know this is extremely insecure and don't see it ever being practical but its what the teacher ...

0
Q: Send muliple individual emails and display details on a web page

johncronI need some help with a problem that's frazzling my gray matter. I'm rewriting my website with Apache, PHP, PEAR & MYSQL the old version was written with Microsoft technologies IIS, ASP & VB. The site serves about 2000 members of which about 600-700 are emailed weekly with various updates (no ...

0
Q: Grouping posts in a category loop by year pages

GasI have a page where I have a big list of books, which are inserted in the loop through a get_posts() query, but since it is too long list, we would like to split it into smaller sections by the year published, and to have two links on top and bottom which would link to the previous/next year grou...

0
Q: memached out-of-the-box fallback solution

usarioI want to use Memached together with native PHP sessions. However, it would be great if there was a simple solution to have the Memcached deamon write the data held in memory to a on-disk database at a fixed interval as a fallback. Are there any solutions for this? I don't want to reinvent the wh...

0
Q: Send Directions from java-script to a micro-controller via php

user2944775So i have a variable in java-script which is storing directions from 1 gps co-ordinate to another. Now i want to send this variable to my micro-controller via php. I don't know how to send the variable from java-script to php and i also don't know how to send the variable from php to the micro-c...

0
Q: I need php code that will display all links which is visted more then 20 times

user2947999I am looking for help in my project. I want to display all those links which are visited more then 20 times and also highest visited site will be at first. I mean if google is visited through my website for 50 times then it will come to rank 1 like 1) [a link]Google[a] now second is facebook w...

0
Q: Long mysql statementns with OR in php?

hookieV2Today I have a noob question but I didn't found any answer on the web, because this is some special issue I think. Im programming a message system with auto refreshing. This is for getting the latest ID in the db: $query = mysql_query("SELECT * FROM `messages` WHERE `requestor`='".$_POST['user_...

 
00:00 - 19:0019:00 - 00:00

« first day (256 days earlier)      last day (54 days later) »