To get a distinct dataset in MySql and embed it into Javascript in JSON format with PHP we need 3 Steps. SQL Source Code 1st. A SQL query to get a unique domain-name list.
11.13.2011
10.27.2011
Categories: Snippets | Add a Comment
The following sample shows how to limit a GROUP_CONCAT string in MySql to a specific length. This methode is near to the better List Aggregate Function in Sybase SqlAnywhere.
05.10.2011
Categories: Snippets | Add a Comment
Because I've nothing found to get the folder of the current active wordpress theme on web server' s filesystem I wrote my own from scratch called get_wp_theme_folder(); PHP Source code: function get_wp_theme_folder(){ $tmp = get_bloginfo("template_url"); $tmp = explode("wp-content/themes/",$tmp); $result = $tmp[1]; // Windows returns slashes in path strings. return str_replace("\\", "/", get_theme_root()."/".$result) ; }
01.18.2011
This is a nice way to get the Domainname form a Url String in Python. import urlparse return urlparse.urlparse(self.request.url)
10.23.2010
If you want to write applications without external dependencies it might be a good idea to embedd resources like images XML or text data into your assembly file. The code snippet below shows how to read embedded resources from an compiled assembly at runtime.
10.23.2010
The following code snippet shows an easy way to determine the root URL of a Web Application within the .Net Framework.
09.23.2010
Categories: Snippets | Add a Comment
This snippet shows a simple solution to generate Slug Urls like WordPress with the Dot Net Framework.