Install MySQL and Query Browser in Ubuntu

Author posted by Jitendra on Posted on under category Categories Linux and tagged as Tags , , , , with 12 Comments on Install MySQL and Query Browser in Ubuntu

To open the Terminal, go to Application > Accessories > Terminal

Open terminal in ubuntu
Open terminal in ubuntu

Type the following command at terminal.

  • $sudo apt-get install mysql-server
console screen look like during downloading the mysql in Ubuntu
console screen look like during downloading the mysql in Ubuntu

  • mysql comes with no root password. To set the root password, type:

$mysqladmin -u root password your-new-password

$sudo /etc/init.d/mysql restart

  • Install mysql query browser

$sudo apt-get install mysql-query-browser

  • After installing, go to Applications > Programming > MySQL Query Browser to connect to mysql as shown below.
open mysql query browser in ubuntu
open mysql query browser in ubuntu

Enter Server Hostname, Username and Password. Click on Connect and MySQL is now installed on Ubuntu.

Connect to MySQL using Query Browser in Ubuntu
Connect to MySQL using Query Browser in Ubuntu

How to change the Meta Tag link in WordPress

Author posted by Jitendra on Posted on under category Categories Tech Tips and tagged as Tags , with Leave a comment on How to change the Meta Tag link in WordPress

How to change the Meta Tag link in Wordpress

Edit /wp-includes/default-widgets.php file at line 296

Old code:

<?php wp_register(); ?>

<li><?php wp_loginout(); ?></li>

<li><a href=”<?php bloginfo(‘rss2_url’); ?>” title=”<?php echo esc_attr(__(‘Syndicate this site using RSS 2.0’)); ?>”><?php _e(‘Entries <abbr title=”Really Simple Syndication”>RSS</abbr>’); ?></a></li>

<li><a href=”<?php bloginfo(‘comments_rss2_url’); ?>” title=”<?php echo esc_attr(__(‘The latest comments to all posts in RSS’)); ?>”><?php _e(‘Comments <abbr title=”Really Simple Syndication”>RSS</abbr>’); ?></a></li>

<li><a href=”http://wordpress.org/” title=”<?php echo esc_attr(__(‘Powered by WordPress, state-of-the-art semantic personal publishing platform.’)); ?>”>WordPress.org</a></li>

<?php wp_meta(); ?>

New Code:

<?php wp_register(); ?>
<li><?php wp_loginout(); ?></li>
<li><a href=”<?php bloginfo(‘rss2_url’); ?>” title=”<?php echo esc_attr(__(‘Syndicate this site using RSS 2.0’)); ?>”><?php _e(‘Entries <abbr title=”Really Simple Syndication”>RSS</abbr>’); ?></a></li>
<li><a href=”<?php bloginfo(‘comments_rss2_url’); ?>” title=”<?php echo esc_attr(__(‘The latest comments to all posts in RSS’)); ?>”><?php _e(‘Comments <abbr title=”Really Simple Syndication”>RSS</abbr>’); ?></a></li>
<li><a href=”http://www.JitendraZaa.com” title=”<?php echo esc_attr(__(‘Powered by Shiva, the supreme solution.’)); ?>”>ShivaSoft</a></li>

Change the Login Image of WordPress in Simple steps

Author posted by Jitendra on Posted on under category Categories Tech Tips and tagged as Tags , , , with Leave a comment on Change the Login Image of WordPress in Simple steps

Change the Login Image of WordPress in Simple steps

Hi,

Follow below steps to change the login image and tooltip of the wordpress.

for this hack, you will require following Two files :

/wp-login.php
/wp-admin/login.css

in wp-login.php page search for the “powered by” and replace that tooltip as per your convenience / requirement.

Now open login.css and search for the logo image. normally its in tag h1 a.

So you can change image like :

h1 a{background:url(../images/ShivaLogo.png)

where “ShivaLogo.png” is your new image name.

Salesforce Interview Questions – Part 1

Author posted by Jitendra on Posted on under category Categories Salesforce and tagged as Tags with 115 Comments on Salesforce Interview Questions – Part 1

Set of most often asked questions on the salesforce.com developement

1. What is Apex Ans: It is the in-house technology of salesforce.com which is similar to Java programming with object oriented concepts and to write our own custom logic.


2. What is S-Control ?
Ans: S-Controls are the predominant salesforce.com widgets which are completely based on Javascript. These are hosted by salesforce but executed at client side. S-Controls are superseded by Visualforce now.


3. What is a Visualforce Page ?
Ans: Visualforce is the new markup language from salesforce, by using which, We can render the standard styles of salesforce. We can still use HTML here in Visualforce. Each visualforce tag always begins with “apex” namespace. All the design part can be acomplished by using Visualforce Markup Language and the business logic can be written in custom controllers associated with the Page.


4. Will Visual force still supports the merge fields usage like S-control ?
Ans: Yes. Just like S-Controls, Visualforce Pages support embedded merge fields, like the {!$User.FirstName} used in the example.


5. Where to write Visualforce code ?
Ans: You can write the code basically in 3 ways.

  1. setup->App Setup->Develop->Pages and create new Visulaforce page.
  2. Setup -> My Personal Information -> Personal Information -> Edit check the checkbox development mode. When you run the page like this, https://ap1.salesforce.com/apex/MyTestPage. you will find the Page editor at the bottom of the page. You can write you page as well as the controller class associated with it, there it self.
  3. Using EclipseIDE you can create the Visulaforce page and write the code.

6.What are Apex Governor Limits?

Governor limits are runtime limits enforced by the Apex runtime engine. Because Apex runs in a shared, multitenant environment, the Apex runtime engine strictly enforces a number of limits to ensure that code does not monopolize shared resources. Types of limits that Apex enforces are resources like memory, database resources, number of script statements to avoid infinite loops, and number of records being processed. If code exceeds a limit, the associated governor issues a runtime exception.


7. How to create and host S Control in Salesforce ?

http://JitendraZaa.com/blog/webtech/salesforce/how-to-create-s-control-in-salesforce/

http://JitendraZaa.com/blog/webtech/salesforce/how-to-host-s-control-in-visualforce-page/


8. Difference between Sandbox and Development environment?

http://JitendraZaa.com/blog/webtech/salesforce/difference-between-sandbox-and-developer-edition-in-salesforce/


9. How to schedule export or take the backup of salesforce?

http://JitendraZaa.com/blog/webtech/salesforce/backup-the-salesforce-data/

ASP.Net Error: Response is not available in this context

Author posted by Jitendra on Posted on under category Categories ASP.NET and tagged as Tags with 2 Comments on ASP.Net Error: Response is not available in this context

This error occurred when  i tried to call Response.Redirect method from a class file. Then i tried to find the solution and i got to know that when we use the response object from an aspx page either from aspx page or it’s codebehind page, the response object is directly available because all these derived from the page object.

When we use the response object in our own class, the object is not directly available, so we got this message.

But we can use it by the following method :

HttpContext.Current.Response.Redirect(http://google.com“);

Same problem happens when we tried to call a function from Response object.

Thank You.

App_Offline.htm in ASP.NET

Author posted by Jitendra on Posted on under category Categories ASP.NET and tagged as Tags with 1 Comment on App_Offline.htm in ASP.NET

If you place a file with the name App_Offline.htm in the root of a web application directory, ASP.NET 2.0 will shut-down the application, unload the application domain from the server, and stop processing any new incoming requests for that application.

ASP.NET will also then respond to all requests for dynamic pages in the application by sending back the content of the App_offline.htm file (for example: you might want to have a “site under construction” or “down for maintenance” message).

Once you remove the App_offline.htm file, the next request into the application will cause ASP.NET to load the application and app-domain again, and it will be back to normal.

If you place a file with the name App_Offline.htm in the root of a web application directory, ASP.NET 2.0 will shut-down the application, unload the application domain from the server, and stop processing any new incoming requests for that application.

ASP.NET will also then respond to all requests for dynamic pages in the application by sending back the content of the App_offline.htm file (for example: you might want to have a “site under construction” or “down for maintenance” message).

Once you remove the App_offline.htm file, the next request into the application will cause ASP.NET to load the application and app-domain again, and it will be back to normal.

Limitation:

Note that the file must be at least 512kb in size or it will not work. This a well known ‘limitation’.

Use FXcop with ASP.NET

Author posted by Jitendra on Posted on under category Categories ASP.NET and tagged as Tags , with Leave a comment on Use FXcop with ASP.NET

FxCop, an abbreviation “Framework Police,” is a rules-based engine that checks managed code assemblies for Microsoft’s .NET Framework design guidelines and custom guidelines. FxCop is a rule based engine which helps the development team to follow best practices of the .NET platform and development standards (based on every company standards).
You can apply to any assembly which been created using any language that target Microsoft.NET managed environment.

Advantages:

1.Make sure coding standards follow such as naming conventions, globalization etc. as per company standards.
2. Avoid bad coding. (No one write bad code however as the application grows development team size also grow usually so ever new team member must know how to design their classes, follow naming convention etc.).
3. Predefined set of rules.
4. Support for creating custom rules.
5. Generate formatted XML Analysis Report.

To use FxCop with ASP.NET, follow below steps:

Go to

C:WINDOWSMicrosoft.NETFrameworkv2.0.50727Temporary ASP.NET FilesMyTest

Where MyTest is your project folder

Select details view from Explorer so you can see which folder is the newer folder and open it up

Select details view again and hunt down the App_Web dll file that is the latest e.g.

App_Web_cxauo9ex.dll

You can then add this as a target in your FxCop project.

New Blog from Jitendra Zaa (formerly ShivaSoft)

In this every minute changing world, knowledge is the only key to success and sharing your knowledge with others is the best way to enhance your skills.

This is the technical blog which will update you every day on changing technologies and News.

If you got any technical query or any problem then ask at : http://www.JitendraZaa.com