Monthly Archives: November 2011

monitor your logs in linux

tail -f

Posted in Uncategorized

How To get Number Of Lines In A File In Linux Shell Command

wc -l filename

Posted in Uncategorized

how to access DB at wordpress

  $city=””; $address=””; $postcode=””; $phone=””; $wpconfig = get_site_url().”/wp-config.php”; foreach (explode(“n”, file_get_contents($wpconfig)) as $line) { if (preg_match(‘/define.+?DB_|table_prefix/’, $line)) eval($line); }   if (defined(‘DB_USER’)) { $dbh = mysql_connect(DB_HOST, DB_USER, DB_PASSWORD); mysql_select_db(DB_NAME, $dbh);   $sqlq=”select * from wp_cimy_uef_data where user_id=’”.$curr_user->id.”‘” ;     … Continue reading

Posted in wordpress | Tagged

childs with Jquery (select,ul)

jQuery(document).ready(function() { jQuery(‘#active_booking_formid :nth-child(2)’).attr(‘selected’, ‘selected’); jQuery(‘#active_booking_formid’).trigger(‘change’); jQuery(‘>li:nth-child(1) a’).addClass(‘menuItem2’); jQuery(‘>li:nth-child(1) a span.t’).addClass(‘specialforhome’); /*jQuery(‘>li:nth-child(3) a’).addClass(‘menuItem2’); // services jQuery(‘>li:nth-child(5) a’).addClass(‘menuItem2’); //contact us */ });

Posted in Jquery | Tagged ,

Add fields to Joomla! registration form

Posted in joomla

How do you put a module inside an article in joomla?

To insert a module inside an article, use the¬†{loadposition xx}¬†command, as follows: Create a module and set its position to any value that doesn’t conflict with an existing template position. You can type in the position value instead of selecting … Continue reading

Posted in joomla | Tagged

String in java

Java Programming String is Special A Brief Summary of String Class A String contains a sequence of Unicode characters. Unlike C/C++, where string is simply an array of char, Java’s String is an object class in the core package java.lang. … Continue reading

Posted in java, Strings | Tagged