Search Results

Search found 23 results on 1 pages for 'kpl'.

Page 1/1 | 1 

  • automysqlbackup not working weirdly on shared host

    - by KPL
    I'm on HostGator and I have not-root-level SSH access. I manually setup automysqlbackup in a /home/user/automysqlbackup folder. Created a file called runbackup in the same folder, chmod +x'ed it. The content : /home/user/automysqlbackup/automysqlbackup /home/user/automysqlbackup/myserver.conf Now, when I run ./runbackup from shell, no email is sent. I've setup a daily cron job. The crontab line reads - 24 06 * * * /home/user/automysqlbackup/runbackup When the crontab is run, I do get an email, but, the subject is WARNING: Error Reported - MySQL Backup Log and SQL Files for localhost - 012-03-19_06h24m The email does have an attachment, but it just has the SQL for creating tables. No data in the several rows at all. I don't know what wrong I'm doing and this is freaking me out! I tried writing a custom script as well, using this guide, but mutt doesn't send email, then. The OS used by HostGator is CentOS.

    Read the article

  • Unable to connect to EC2 instance after "reboot"

    - by KPL
    I am not able to connect to my m1.small instance after rebooting it. I have already associated the public IP with this instance. Upon checking the system log, this seems to be the issue: cloud-init-nonethttp://11.84: waiting 10 seconds for network device cloud-init-nonethttp://21.85: waiting 120 seconds for network device cloud-init-nonethttp://141.85: gave up waiting for a network device. Cloud-init v. 0.7.3 running 'init' at Sun, 18 May 2014 07:02:55 +0000. Up 142.54 seconds. ci-info: +++++++++++++++++++++++Net device info++++++++++++++++++++++++ ci-info: +--------+-------+-----------+-----------+-------------------+ ci-info: | Device | Up | Address | Mask | Hw-Address | ci-info: +--------+-------+-----------+-----------+-------------------+ ci-info: | lo | True | 127.0.0.1 | 255.0.0.0 | . | ci-info: | eth0 | False | . | . | 02:43:xx:xx:xx:xx | ci-info: +--------+-------+-----------+-----------+-------------------+ ci-info: !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!Route info failed!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! A bunch of these follow the above message: 2014-05-18 07:02:56,178 - url_helper.pyWARNING: Calling http://169.254.169.254/2009-04-04/meta-data/instance-id failed 0/120s: request error [HTTPConnectionPool(host='169.254.169.254', port=80): Max retries exceeded with url: /2009-04-04/meta-data/instance-id (Caused by : Errno 101] Network is unreachable) This is obviously related to the network interface not being working correctly. I have tried this so far: Relaunch a new instance from the custom AMI (created from EBS) of the failing instance. The same error shows up in the logs. Attach a new network interface to the EC2 instance. The error still persists. eth1 shows up in the list but the "up" column is False.

    Read the article

  • MongoDB data directory transfer and upgrade

    - by KPL
    I just transferred my data directory (of Mongo 1.6.5) to a new server and installed Mongo 2.0 on it. I set the data directory path and did sudo server mongod restart. It failed, and the log file output says this - ***** SERVER RESTARTED ***** Sun Oct 9 07:51:47 [initandlisten] MongoDB starting : pid=8224 port=27017 dbpath=/database/mongodb 64-bit host=domU-12-31-39-09-35-81 Sun Oct 9 07:51:47 [initandlisten] db version v2.0.0, pdfile version 4.5 Sun Oct 9 07:51:47 [initandlisten] git version: 695c67dff0ffc361b8568a13366f027caa406222 Sun Oct 9 07:51:47 [initandlisten] build info: Linux bs-linux64.10gen.cc 2.6.21.7-2.ec2.v1.2.fc8xen #1 SMP Fri Nov 20 17:48:28 EST 2009 x86_64 BOOST_LIB_VERSION=1_41 Sun Oct 9 07:51:47 [initandlisten] options: { auth: "true", config: "/etc/mongod.conf", dbpath: "/database/mongodb", fork: "true", logappend: "true", logpath: "/var/log/mongo/mongod.log", nojournal: "true" } Sun Oct 9 07:51:47 [initandlisten] couldn't open /database/mongodb/local.ns errno:1 Operation not permitted Sun Oct 9 07:51:47 [initandlisten] error couldn't open file /database/mongodb/local.ns terminating Sun Oct 9 07:51:47 dbexit: Sun Oct 9 07:51:47 [initandlisten] shutdown: going to close listening sockets... Sun Oct 9 07:51:47 [initandlisten] shutdown: going to flush diaglog... Sun Oct 9 07:51:47 [initandlisten] shutdown: going to close sockets... Sun Oct 9 07:51:47 [initandlisten] shutdown: waiting for fs preallocator... Sun Oct 9 07:51:47 [initandlisten] shutdown: closing all files... Sun Oct 9 07:51:47 [initandlisten] closeAllFiles() finished Sun Oct 9 07:51:47 [initandlisten] shutdown: removing fs lock... Sun Oct 9 07:51:47 dbexit: really exiting now I have already run it with --upgrade once.

    Read the article

  • How to add custom fields in WordPress "Add a New Post" page?

    - by KPL
    Hello awesome people, I want to add a custom field on Add A New Post page. Like - if I am to make a plugin which will post links to Twitter after a new post is made, I would like to give ability to user to select if he wants to tweet that particular post's link to Twitter. I want to display a check box somewhere in the page which says - "Post this on Twitter" and then check for it and make a tweet. I have seen some plugins which do this. But can't remember which they were. Can someone please help me out?

    Read the article

  • Twitter-OAuth update_profile_*_image methods problem [EpiTwitter]

    - by KPL
    People, I have been struggling over the two methods - Update Profile Image and Update Background Image I am using EpiTwitter library. I am uploading GIFs, Twitter returns the expected result for update_profile_background_image but returns 401 for update_profile_image , but the image is not changed. Here are the headers catched from $apiObj-headers in my case while using the update_profile_background_image Array ( [Date] = Sat, 24 Apr 2010 17:51:36 GMT [Server] = hi [Status] = 200 OK [X-Transaction] = 1272131495-55190-23911 [ETag] = b6a421c01936f3547802ae6b59ee7ef3" [Last-Modified] = Sat, 24 Apr 2010 17:51:36 GMT [X-Runtime] = 0.13990 [Content-Type] = application/json; charset=utf-8 [Content-Length] = 1272 [Pragma] = no-cache [X-Revision] = DEV [Expires] = Tue, 31 Mar 1981 05:00:00 GMT [Cache-Control] = no-cache, no-store, must-revalidate, pre- check=0, post-check=0 [Set-Cookie] = *REMOVED* [Vary] = Accept-Encoding [Connection] = close ) and for update_profile_image - Array ( [Date] => Sat, 24 Apr 2010 17:57:58 GMT [Server] => hi [Status] => 401 Unauthorized [WWW-Authenticate] => Basic realm="Twitter API" [X-Runtime] => 0.02263 [Content-Type] => text/html; charset=utf-8 [Content-Length] => 152 [Cache-Control] => no-cache, max-age=300 [Set-Cookie] => *REMOVED* [Expires] => Sat, 24 Apr 2010 18:02:58 GMT [Vary] => Accept-Encoding [Connection] => close ) Can somebody help me out?

    Read the article

  • [PHP] missing keys in $_POST

    - by KPL
    Hello there, I am trying to get some form data from POST method. Here's the code of form - <form action="" method="post" name="form1" id="form1"> <input type="hidden" value="15" name="ad_id"> <table width="100%" cellspacing="0" cellpadding="0" border="0" class="block"> <tbody><tr> <td valign="top">&nbsp;</td> <td align="right">all fields are required</td> </tr> <tr> <td valign="top">&nbsp;</td> <td align="center"></td> </tr> <tr> <td valign="top" width="150"><label for="name">Advertisement Name</label> *</td> <td><input type="text" size="45" value="Banner" id="name" name="name"> e.g Home Banner</td> </tr> <tr> <td valign="top"><label for="placement">Advertisement Placement</label></td> <td><select id="placement" name="placement"> Wide Skyscrapper 160 x 600 </tr> <tr> <td valign="top"><label for="code">Advertisement Code</label></td> <td><textarea rows="5" cols="45" id="code" name="code"></textarea></td> </tr> <tr> <td>Status</td> <td><label> <input type="radio" checked="checked" value="1" name="status"> Active</label> <label> <input type="radio" value="0" name="status"> Inactive</label></td> </tr> <input type="hidden" value="1" name="banner_uploaded" id="banner_uploaded"> <tr> <td>For Country - </td> <td> <select id="country" name="country"> <option>Not posting all the names of country</option> </select> </td> </tr> <tr> <td><label for="Scheduling">Valid From </label></td> <td><input type="text" value="" id="date-from" name="date-from"> Format : dd/mm/yyyy:hh/mm</td> </tr> <tr> <td><label for="Scheduling">Valid Till </label></td> <td><input type="text" value="" id="date-to" name="date-to"> Format : dd/mm/yyyy:hh/mm</td> </tr> <tr> <td>&nbsp;</td> <td align="right"><input type="submit" onclick="return validate_ad_form(add_adv)" value="Update Advertisement" class="button" name="update"></td> </tr> </tbody></table> </form> But I am getting $_POST['code'] empty when I am passing HTML code through it. When I pass plain text, it works fine. When I printed $_POST [i.e. used - print_r($_POST) ], I got the following output - Array ( [ad_id] = 15 [name] = Banner [placement] = ad_468x60 [code] = [status] = 1 [banner_uploaded] = 1 [country] = IN [date-from] = [date-to] = [update] = Update Advertisement ) Please be known, I haven't entered the 'date-from','date-to' fields. I have entered on purpose as StackOverflow don't allow me to post images! People,any help will be highly appreciated.

    Read the article

  • How to get the page in a variable which is going to be displayed in Wordpress ?

    - by KPL
    I want to get the content which are displayed by a particular page in WordPress back-end. Say, for [ROOT]/wp-admin/profile.php I want to remove the First Name and Last Name fields from this page. So, I can run a str_replace() to remove the lines. In this case, I have $search and $replace ... but I need $subject [Ref - http://php.net/manual/en/function.str-replace.php] How to get the $subject ? OR, anybody know any other way to do this?

    Read the article

  • [PHP-GD] How to use imagefill() from file?

    - by KPL
    Hello people, Thanks for looking at this question. I wanted to know how can I use the GD function imagefill() to patch an image with another image. imagefill() currently accepts resource of a color. I can do that. But wanted to know how this can be done with a file. I noticed a user note - But that didn't worked and took a long time for completion :-( http://www.php.net/manual/en/function.imagefill.php#84288

    Read the article

  • add_filter() not working in WordPress

    - by KPL
    Hello everybody, I just came across a problem, here's my code - function unFilterPostData() { $content = get_the_content(); return $content . 'Contact author on Twitter - @alilpirate'; } add_filter('the_content','unFilterPostData'); I have also tried using function unFilterPostData($content) { return $content . 'Contact author on Twitter - @alilpirate'; } add_filter('the_content','unFilterPostData'); But nothing works. Help!

    Read the article

  • How to display HTML after video play finishes?

    - by KPL
    Hello people, I am new here. I would like to know how can I display HTML code after a video is finished playing. I am using FlowPlayer (http://www.flowplayer.org) . I have tried to achieve this using JW Flash Player (http://www.longtailvideo.com/players/jw-flv-player/), but was unable figure out anything. Also, let me know if it's possible or not. And if it is, please share with me and everybody on StackOverflow. P.S. I am using PHP.

    Read the article

  • How do I use CSS to add a non-rectangular border around an image?

    - by KPL
    Hello people, I have three images, and they are not square or rectangular in shape. They are just like face of anyone. So, basically, my images are in the size 196x196 or anything like that, but complete square or rectangle with the face in the middle and transperant background in the rest of the portion. Now, I want to remove the transperant background too and just keep the faces. Don't know if this is possible and mind you, this isn't a programming question. EDIT (from comments): How do I put a border around the shape of the image, not a rectangular one around the boundary, using CSS.

    Read the article

  • Removing the transparency from image while keeping the actual image

    - by KPL
    Hello people, I have three images,and , they are not square or rectangular in shape. They are just like face of anyone. So, basically, my images are in the size 196x196 or anything like that, but complete square or rectangle with the face in the middle and transperant background in the rest of the portion. Now, I want to remove the transperant background too and just keep the faces. Don't know if this is possible and mind you, this isn't a programming question.

    Read the article

  • Removing the transperancy from image while keeping the actual image

    - by KPL
    Hello people, I have three images,and , they are not square or rectangular in shape. They are just like face of anyone. So,basically, my images are in the size 196x196 or anything like that, but complete square or rectangle with the face in the middle and transperant background in the rest of the portion. Now, I want to remove the transperant background too and just keep the faces. Don't know if this is possible and mind you, this isn't a programming question.

    Read the article

  • How to write mod_security friendly PHP code?

    - by KPL
    Hello people, I made a theme in WordPress which hit the mod_security rule on HostGator and gave 403 error. I contacted people there(at HostGator) and they fixed it for me. But I don't want my theme to work like this. I just wanted to know if there are any guides/blog post/tutorials telling about writing PHP code which is mod_security friendly? I tried Google, but didn't find anything helpful.

    Read the article

  • Unable to relate two MySQL tables (foreign keys)

    - by KPL
    Hello people, Here's my USER table CREATE TABLE IF NOT EXISTS `users` ( `id` int(11) NOT NULL AUTO_INCREMENT, `username` varchar(100) NOT NULL, `expiry` varchar(6) NOT NULL, `contact_id` int(11) NOT NULL, `email` varchar(255) NOT NULL, `password` varchar(100) NOT NULL, `level` int(3) NOT NULL, `active` tinyint(4) NOT NULL DEFAULT '1', PRIMARY KEY (`id`,`email`) ) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ; And here's my contact_info table CREATE TABLE IF NOT EXISTS `contact_info` ( `id` int(11) NOT NULL AUTO_INCREMENT, `name` varchar(255) NOT NULL, `email_address` varchar(255) NOT NULL, `company_name` varchar(255) NOT NULL, `license_number` varchar(255) NOT NULL, `phone` varchar(30) NOT NULL, `fax` varchar(30) NOT NULL, `mobile` varchar(30) NOT NULL, `category` varchar(100) NOT NULL, `country` varchar(20) NOT NULL, `state` varchar(20) NOT NULL, `city` varchar(100) NOT NULL, `postcode` varchar(50) NOT NULL, PRIMARY KEY (`id`,`email_address`), ) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ; The system uses username to login users.I want to modify it in such a way that it uses email for login. But there's no email_address in users table. I have added foreign key - email in user table(which is email_address in contact_info). How should I query database?

    Read the article

  • [PHP] - Output buffer based progress bar

    - by KPL
    Hello people, I have been trying to get the following code working. It's a progress bar trick which uses ob_get_clean() function. Don't know why but this script just don't work! Only the initial percent - 1% comes up and nothing after that. <?php error_reporting(8191); function flush_buffers(){ @ob_end_flush(); @ob_flush(); @flush(); @ob_start(); } $ini = 2; echo '<script>document.getElementById(\'lpt\').style.width=\'1%\';</script><br>'; for($i=1;$i<=100;$i++) { $k=$ini-1; $str=str_replace("width=\'$k%\'","width=\'$i%\'",ob_get_clean()); $ini++; echo $str; flush_buffers(); } ?>

    Read the article

  • Background image not getting vertically stretched in Chrome.

    - by KPL
    Hi all, The CSS - #header { overflow: hidden; background: url(images/header-bg.png) top repeat-x #FFFFFF; position: relative; border: none; display: block; height: 125px; width:100%; } The HTML - <div id="header"> <a href="http://localhost/" title="Dev" id="logo"><img src="images/logo.png" alt="" /></a> </div> This works good in Firefox - But not in Chrome :( - The image isn't being stretched vertically in Chrome. Help! Just a note, I'm on Linux.

    Read the article

  • [PHP-GD] Background transperancy in imagerotate()

    - by KPL
    Hello people, Since last 2 days, I was trying to add transperancy to the background after rotating an image using imagerotate() PHP-GD function. But, to my great disappointment, it's not working at all. It's just giving out a black background behind it. Here's my code - $patchImageS = 'image.png'; // the image to be patched over the final bg $patchImage = imagecreatefrompng($patchImageS); // resource of image to be patched $patchImage = imagerotate($patchImage, 23, 0, 0); imagepng($patchImage,'tt.png'); I tried to change the parameters being passed in function to imagerotate($patchImage, 23, 5, 0); imagerotate($patchImage, 23, 0, 5); Any help would be highly appreciated.

    Read the article

  • Closing the iframe which was opened for "ajax uploading"

    - by KPL
    Hello people, http://www.atwebresults.com/php_ajax_image_upload/ I am using this script for so-called AJAX file upload but which is actually based on opening of iframe and then submitting form from it. What my problem is, I am using this script in a form which will have some other fields too. So after uploading the image, when I click submit at the end of the form, the form is submitted to the file which was opened in iFrame. As I am not an expert in JS, can you guys help me with this? I tried changing the action attribute and tried to completely remove the form too, but nothing helped.

    Read the article

  • Getting $n number of maximum values

    - by KPL
    Hello all, Straight to the question - If $n = 3, and input is - Array ( [04] => 3 [07] => 4 [01] => 5 [06] => 5 [05] => 5 [03] => 6 [08] => 6 [02] => 7 [09] => 8 [12] => 9 [10] => 10 [15] => 10 [19] => 11 [20] => 11 [13] => 12 [21] => 12 [16] => 13 [14] => 14 [22] => 14 [23] => 15 [11] => 15 [00] => 15 [17] => 17 [18] => 17 ) Output should be - Array ( [14] => 14 [22] => 14 [23] => 15 [11] => 15 [00] => 15 [17] => 17 [18] => 17 ) Thank you, all, for help.

    Read the article

  • Grouping arrays with consecutive keys

    - by KPL
    Hello people, I've an array like this - Array ( [16] => 424 [17] => 404 [18] => 416 [21] => 404 [22] => 456 [23] => 879 [28] => 456 [29] => 456 [32] => 123 [35] => 465 ) The output of this array would be Array ( [0] => Array ( ['start'] => 16 ['stop'] => 18 ) [1] => Array ( ['start'] => 21 ['stop'] => 23 ) [2] => Array ( ['start'] => 28 ['stop'] => 29 ) [3] => Array ( ['start'] => 32 ['stop'] => 33 ) [4] => Array ( ['start'] => 35 ['stop'] => 36 ) ) I don't really need the values. Just grouping the keys. And if consecutive integer doesn't exist for a particular key(like for [32] and [35]), 'stop' should be the consecutive integer. Thank you all for help.

    Read the article

1