This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8"> | |
<title>POST Page - WP Bootstrap Temple</title> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<meta name="description" content=""> | |
<meta name="author" content=""> | |
<!-- Le styles --> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div id="myCarousel" class="carousel slide"> | |
<!-- Carousel items --> | |
<div class="carousel-inner"> | |
<div class="active item"><img src="images/car_blackmusclecar.jpg" alt="Car Carousel" /></div> | |
<div class="item"><img src="images/car_bluetruck.jpg" alt="Car Carousel" /></div> | |
<div class="item"><img src="images/car_blackspeedster.jpg" alt="Car Carousel" /></div> | |
<div class="item"><img src="images/car_redback.jpg" alt="Car Carousel" /></div> | |
<div class="item"><img src="images/car_cyanclassic.jpg" alt="Car Carousel" /></div> | |
<div class="item"><img src="images/car_redgrill.jpg" alt="Car Carousel" /></div> | |
<div class="item"><img src="images/car_purplefire.jpg" alt="Car Carousel" /></div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$the_url = isset($_REQUEST['url']) ? htmlspecialchars($_REQUEST['url']) : ''; | |
?> | |
<form method="post"> | |
Please enter full URL of the page to parse (including http://):<br /> | |
<input type="text" name="url" size="65" value="<?php echo $the_url; ?>"/><br /> | |
or enter text directly into textarea below:<br /> | |
<textarea name="text" cols="50" rows="15"></textarea> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
import_request_variables('gpc'); | |
$host = ''; // <-- db address | |
$user = ''; // <-- db user name | |
$pass = ''; // <-- password | |
$db = 'rsvp_list'; // db's name | |
$table = 'guest_list'; // table you want to export | |
$file = '6am_event_guest_list'; // csv name. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$contenttograbimagefrom = $youroriginalhtmlwithimage; | |
$firstImage = ""; | |
$output = preg_match_all('/<img.+src=[\'"]([^\'"]+)[\'"].*>/i', $contenttograbimagefrom, $ContentImages); | |
$firstImage = $ContentImages[1] [0]; // To grab the first image | |
echo $firstImage; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
* To change this template, choose Tools | Templates | |
* and open the template in the editor. | |
*/ | |
if ($handle = opendir('/media/book')) { | |
echo "Directory handle: $handle\n"; | |
echo "Files:\n"; | |
/* This is the correct way to loop over the directory. */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// calculate start and end dates of the week | |
// 0 = Sunday | |
echo date("Y-m-d", strtotime(date("Y").'W'.date('W')."0")); | |
// 7 = Saturday | |
echo date("Y-m-d", strtotime(date("Y").'W'.date('W')."7")); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
doctrine ile kodlama yaparken mümkün oldukça array olarak döndürelim | |
--------------------------------------------------------------------- | |
*/ | |
public function getUserId($username) { | |
$user = Doctrine_Query::create() | |
->select('u.id, u.user_name') | |
->from('User u') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$dataProvider=new CActiveDataProvider('Post', array( | |
'criteria'=>array( | |
'condition'=>'status=1', | |
'order'=>'create_time DESC', | |
'with'=>array('author'), | |
), | |
'pagination'=>array( | |
'pageSize'=>20, | |
), |
OlderNewer