RSS and Atom Feed Reader Online

Code Sharing Repository

Public source code sharing repository

YouTube video thumbnails size - Code Sharing Repository

https://img.youtube.com/vi/ /maxresdefault.jpg 1280 x 720 https://img.youtube.com/vi/ /sddefault.jpg 640 x 480 https://img.youtube.com/vi/ /hqdefault.jpg 480 x 360 https://img.youtube.com/vi/ /mqdefault.jpg 320 x 180 https://img.youtube.com/vi/...

Posted on 13 May 2019 | 5:24 am

SimplePie - Smarty example - Code Sharing Repository

//PHP File require_once ('autoloader.php'); $feed = new SimplePie(); $feed->set_feed_url('http://feeds.feedburner.com/TechCrunch/'); $feed->init(); $feed->handle_content_type(); if ($feed->error()) { echo $feed->error(); } foreach...

Posted on 10 May 2019 | 12:17 pm

Exim filter example - Code Sharing Repository

if $message_body: contains "Something you dont want" then fail text "Your mail is not welcome." seen finish endif if $message_body: contains "Something you dont want" or $message_body: contains "Also I dont want this" then fail endif

Posted on 5 May 2019 | 1:44 pm

Bootstrap 4 How to open external url in modal dialog - Code Sharing Repository

Launch demo modal Modal title × my-remote-file.php content Close...

Posted on 2 May 2019 | 4:15 pm

Highlight String Example - Code Sharing Repository

'; echo ' '; highlight_string($string); echo ' '; ?>

Posted on 20 January 2019 | 8:37 pm

Sending HTML Email With Image - Code Sharing Repository

Email With Image Sending HTML Email With Image ' . $message . ' '; $headers = 'MIME-Version: 1.0' . "\r\n"; $headers .= 'Content-type: text/html; charset=utf-8' . "\r\n"; $headers .= 'From:...

Posted on 20 January 2019 | 7:48 pm

Display and log errors - Code Sharing Repository

error_reporting(E_ALL); ini_set('display_errors', TRUE); ini_set('log_errors', TRUE); ini_set('error_log', 'php.log');

Posted on 8 December 2018 | 5:48 pm

Block googlebot robots.txt - Code Sharing Repository

User-agent: Googlebot Disallow: /

Posted on 28 November 2018 | 12:01 am

htaccess redirect http to https - Code Sharing Repository

RewriteEngine On RewriteCond %{HTTPS} off RewriteRule .* https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301] RewriteCond %{HTTP_HOST} !^www\. [NC] RewriteRule .* https://www.%{HTTP_HOST}%{REQUEST_URI} [L,R=301]

Posted on 23 June 2018 | 11:07 am

ADOdb - Check if MySQL query executed successfully - Code Sharing Repository

Prepare('DELETE FROM mytable WHERE id = ' . $DB->qstr($id) . ''); if ($DB->Execute($sql) === false) { print $DB->ErrorMsg(); } if ($DB->affected_rows() !== 0) { //true } ?>

Posted on 29 May 2018 | 4:20 pm

Article Structured data Schema Markup - Code Sharing Repository

My Article Name My Description Name Website Articles 4 out of 5 stars based on 1 votes

Posted on 21 May 2018 | 4:27 am

Bootstrap 4 change input placeholder color - Code Sharing Repository

.form-control::-webkit-input-placeholder { color: #bbb; }

Posted on 13 May 2018 | 3:51 pm

Change arrow size and colors in Bootstraps carousel - Code Sharing Repository

.carousel-control-prev-icon { background-image: url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23f8f8f8' viewBox='0 0 8 8'%3E%3Cpath d='M5.25 0l-4 4 4 4 1.5-1.5-2.5-2.5 2.5-2.5-1.5-1.5z'/%3E%3C/svg%3E"); }...

Posted on 24 April 2018 | 2:27 pm

ADOdb count number of records - Code Sharing Repository

$recordSet = $conn->Execute('SELECT * FROM mytable where published = '.$conn->qstr('1').' or published = '.$conn->qstr('2').' order by id DESC'); $counter = $recordSet->recordCount(); echo $counter;

Posted on 8 April 2018 | 4:14 am

Exim - How to block certain domain - Code Sharing Repository

1. In etc/exim/exim.conf after this line: # $Cambridge: exim/exim-src/src/configure.default,v 1.14 2009/10/16 07:46:13 tom Exp $ put this line: system_filter = /etc/exim/filters 2. Create file filters in /etc/exim/ folder with code: if $header_from: contains...

Posted on 28 February 2018 | 11:02 am

SSH IPTables command to block IP Address - Code Sharing Repository

[[email protected] ~]# iptables -A INPUT -s x.xx.xx.xx -p tcp --dport 25 -j REJECT [[email protected] ~]# service iptables save [[email protected] ~]# service iptables restart

Posted on 27 February 2018 | 9:41 am

Warning: purging the environment. Suggested action: use keep_environment issue - Code Sharing Repository

1. Open etc/exim/exim.conf 2. Directly after this code line: # $Cambridge: exim/exim-src/src/configure.default,v 1.14 2009/10/16 07:46:13 tom Exp $ add: keep_environment = X-SOURCE : X-SOURCE-ARGS : X-SOURCE-DIR add_environment =...

Posted on 27 February 2018 | 9:25 am

htaccess redirect www to non-www - Code Sharing Repository

RewriteEngine On RewriteCond %{HTTP_HOST} ^www\.(.*)$ [NC] RewriteRule ^(.*)$ http://%1/$1 [R=301,L]

Posted on 19 February 2018 | 11:28 pm

Smarty XML / RSS example file - Code Sharing Repository

Site Name Site Description http://www.example.com {section name=foo loop=$foo} {$foo[foo].progname|stripslashes|replace:"'":''|replace:'"':''|escape:'htmlall':'UTF-8'|replace:'&':'...

Posted on 9 February 2018 | 6:41 am

Full text search order by relevance - Code Sharing Repository

SELECT SQL_CALC_FOUND_ROWS *, MATCH (title,description) AGAINST ('Text') as score FROM posts WHERE MATCH (title,description) AGAINST ('Text') ORDER by score DESC;

Posted on 13 December 2017 | 5:18 am