Advertisement

Send JSON data via POST to PHP

2017-08-12

I'm trying to send the JSON below to a PHP script via the POST method. { "operation": { "name": "Nicolas", "age": 24, "sex": "Male", } } What I want to do is manage the information that comes fro

Analyze the Google Geocode json response

2017-08-12

I'm trying to analyze a response from a Google API. I wonder if there is an easy / efficient way to parse this table in php to get the data from the 'address_components' array. { "results" : [ { "address_components" : [ { "long_na

do not find mvc class

2017-08-12

This is my project .htaccess in mvc RewriteEngine on RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-l RewriteRule ^(.+)$ index.php?url=$1 [QSA,L] This is my simple class in the controllers fo

CSRF Codeigniter 3 Validation

2017-08-12

I have read about crsf protection in the codeignitor, but I can not find a decent tutorial on how to proceed after enabling csrf in the configuration file. I have a form generated by a users/create controller function that submits to another users/su

Disable prettyPhoto in WordPress Child Theme

2017-08-12

I use a WordPress theme - Rock 'n' Rolla that uses prettyPhoto because it's the default lightbox for picture galleries. I built a child theme and I want to disable prettyPhoto to replace it with a different lightbox solution. In the functions.php fil

How to include the new file / class php in yii2?

2017-08-12

I want to include the pagination ajax class to yii2. How do I do that? when I use the code below: basePath.'/../vendor/phpunit/phpunit/src/Extensions/Pagination.php'; include $url; ?> in the controller and also under the code: require_once Yii::app()

Result: Blank Page (Php)

2017-08-12

Hello guys, I'm a beginner and I started to learn php. I followed tutorials and learned something about how to fix errors as long as errors are declared / displayed. But I have this problem in my code where it does not show my site, it simply shows a

How do I return data in Laravel from Vue.js Axios

2017-08-12

I have a text box and I try to submit data with axios and view to laravel but that does not work. I try to take the data and put it first and then return it. new Vue({ el:'#root', data:{ areamodel: '' }, methods:{ insert:function(){ axios.post('/vue'

Query WP Sql - this must be correct :-(

2017-08-12

I'm trying to make a very simple SQL query in Wordpress. I do not know why, but it does not work :-( $my_query = ("SELECT DISTINCT meta_value FROM wp_usermeta WHERE meta_key = 'schoolcountry'"); $vysledek = $wpdb->get_results($my_query); fore

Download large file does not work

2017-08-12

As the title says I have a problem with downloading the video. I have to create a form that allows to download a file in a folder, it works with photos, and even with videos (or anyway, the .mp4 file). The problem comes when I try to download large f

Advanced Wordpress SQL Query

2017-08-12

after 4 hours I can not find a solution, how to write the SQL query correctly to echo data from two tables. I have two tables and I have to "JOIN" their data. The first table is "wp_users" and the second is "wp_usermeta". Fro

MySQL limits a time range of a range of 10

2017-08-12

I try to create a range of temperature readings in a time interval, but limit it to only 1 reading for every 10 reads. Can anyone help me add this function to the code below? :) $dataArray=array(); $sql="SELECT * FROM $sensorID WHERE Time > DATE_S

get the file extension during php download

2017-08-12

I try to add the file extension to my file during the download. As I find it hard to do, I already coded it in a small .jpeg case in my script. How can I get rid of the hard coded file extension and dynamically replace it with the original loaded as