You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Identify WebCEO Bot Request - Block unwanted page requests from automated Competitor Metrics & Backlink Spy (They don't provide a way for sites to opt-out or use WebCEO-specific robots.txt rules.)
This file contains hidden or 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
Block unwanted page requests from automated Competitor Metrics & Backlink Spy (They don't provide
a way for sites to opt-out or use WebCEO-specific robots.txt rules.)
*/
function isWebCEO(){
return YesNoFormat(ListFind("97.107.131.214,69.164.220.17,69.164.220.10,69.164.208.136,69.164.208.68,97.107.135.120,97.107.135.14,69.164.212.131,97.107.133.236,97.107.131.160", CGI.Remote_Addr) OR Findnocase("seo-audit-check-bot", CGI.http_User_Agent) OR Findnocase("online-webceo-bot", CGI.http_User_Agent));
An update to a ColdFusion-based limiter UDF to throttle requests. Using HTTP status 429, CacheGet/Push (for automatic collection flushing) and cookie filters.
This file contains hidden or 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
- Throttles requests made more than "count" times within "duration" seconds from single IP.
- sends 503 status code for bots to consider as well as text for humans to read
- also logs to a new "limiter.log" that is created automatically in cf logs directory, tracking when limits are hit, to help fine tune
- note that since it relies on the application scope, you need to place the call to it AFTER a cfapplication tag in application.cfm
- updated 10/16/12: now adds a test around the actual throttling code, so that it applies only to requests that present no cookie, so should only impact spiders, bots, and other automated requests. A "legit" user in a regular browser will be given a cookie by CF after their first visit and so would no longer be throttled.
- I also tweaked the cflog output to be more like a csv-format output
Optimized my.cnf configuration for MySQL/MariaDB (on cPanel/WHM servers)
This file contains hidden or 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
HowTo have specific .gitignore for each git branch
How to have specific .gitignore for each git branch
Objective
My objective is to have some production files ignored on specific branches. Git doesn't allow to do it.
Solution
My solution is to make a general .gitignore file and add .gitignore.branch_name files for the branches I want to add specific file exclusion.
I'll use post-checkout hook to copy those .gitignore.branch_name in place of .git/info/exclude each time I go to the branch with git checkout branch_name.
Read an SDS011 Laser PM2.5 Sensor (Nova PM Sensor) with Python
This file contains hidden or 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
Identify WebCEO Bot Request - Block unwanted page requests from automated Competitor Metrics & Backlink Spy (They don't provide a way for sites to opt-out or use WebCEO-specific robots.txt rules.)
This file contains hidden or 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
Block unwanted page requests from automated Competitor Metrics & Backlink Spy (They don't provide
a way for sites to opt-out or use WebCEO-specific robots.txt rules.)
*/
function isWebCEO(){
return YesNoFormat(ListFind("97.107.131.214,69.164.220.17,69.164.220.10,69.164.208.136,69.164.208.68,97.107.135.120,97.107.135.14,69.164.212.131,97.107.133.236,97.107.131.160", CGI.Remote_Addr) OR Findnocase("seo-audit-check-bot", CGI.http_User_Agent) OR Findnocase("online-webceo-bot", CGI.http_User_Agent));
This file contains hidden or 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
The perfect Varnish configuration for WordPress, Joomla, Drupal & other (common) CMS based websites
The perfect Varnish configuration for WordPress, Joomla, Drupal & other (common) CMS based websites
Updated on December 15th, 2021
IMPORTANT: Read this before implementing one of the configuration files below (for either Varnish 3.x or 4.x+).
USE: Replace the contents of the main Varnish configuration file located in /etc/varnish/default.vcl (root server access required - obviously) with the contents of the configuration you'll use (depending on your Varnish version) from the 2 examples provided below.
IMPORTANT: The following setup assumes a 180 sec (3 minute) cache time for cacheable content that does not have the correct cache-control HTTP headers. You can safely increase this to 300 sec (or more) for less busier sites or drop it to 60 sec or even 30 sec for high traffic sites. It obviously depends on your use case.
This file contains hidden or 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
ColdFusion ExifTool.CFC update to enable gathering all metadata in a single call w/option to save result as JSON file.
This file contains hidden or 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