Vrundesha Joshi

Vrundesha Joshi

218 Articles Published

Articles by Vrundesha Joshi

Page 5 of 22

How to create a session only cookies with JavaScript?

Vrundesha Joshi
Vrundesha Joshi
Updated on 16-Jun-2020 1K+ Views

To create a session only cookie, you need to set the expiration date of the cookie to be some years ahead. You need to set the expire attribute −current time + 5 yearsThe expire attribute shows the date the cookie will expire. If this is blank, the cookie will expire when the visitor quits the browser.Note − Do not consider removing the expire value to create a session only cookie. This won’t work. Set the expire attribute to the future date.

Read More

Create a list group heading in Bootstrap

Vrundesha Joshi
Vrundesha Joshi
Updated on 12-Jun-2020 3K+ Views

To create a list group heading, use the .list-group-item-heading class in Bootstrap.You can try to run the following code to implement .list-group-item-heading class −ExampleLive Demo           Bootstrap Example                                          Countries                                      Asia                India                Nepal                                        Europe                Germany                Italy                Spain                                

Read More

How to use Bootstrap Alert Plugins

Vrundesha Joshi
Vrundesha Joshi
Updated on 12-Jun-2020 177 Views

Alert messages are used to display information such as warning or confirmation messages to the end users. You can try to run the following code to implement alert plugins in Bootstrap −ExampleLive Demo            Bootstrap Example                                          ×          Success! the result is successful.                      $(function(){             $("#myAlert").bind('closed.bs.alert', function () {                alert("Alert message box is closed.");             });          });          

Read More

Add a green background color to an element to set positive action with Bootstrap

Vrundesha Joshi
Vrundesha Joshi
Updated on 12-Jun-2020 220 Views

Use the .btn-success class in Bootstrap to set a positive action to an element. You can try to run the following code to implement the .btn-success class −ExampleLive Demo           Bootstrap Example                                 The following are FMCG companies:                ITC Limited          Nestle          Britannia Industries Limited             Click below if the above list is correct:       Success    

Read More

Add HTML paragraphs into Bootstrap thumbnails

Vrundesha Joshi
Vrundesha Joshi
Updated on 12-Jun-2020 204 Views

With Bootstrap, you can easily add paragraphs to thumbnails.You can try to run the following code to add HTML paragraphs −ExampleLive Demo           Bootstrap Example                                                                                                              Thumbnail label                This is demo paragraph! This is demo paragraph! This is demo paragraph! This is demo paragraph! This is demo paragraph! This is demo paragraph!                This is demo paragraph! This is demo paragraph! This is demo paragraph! This is demo paragraph! This is demo paragraph!                                

Read More

What is the use of JavaScript eval function?

Vrundesha Joshi
Vrundesha Joshi
Updated on 12-Jun-2020 396 Views

The JavaScript eval() is used to execute an argument. The code gets execute slower when the eval() method is used. It also has security implementations since it has a different scope of execution. In addition, use it to evaluate a string as a JavaScript expression.The eval() method is not suggested to use in JavaScript since it executes slower and improper usage opens your website to injection attacks.ExampleHere’s how you can implement eval() functionLive Demo                    var a = 30;          var b = 12;          var res1 = eval("a * b") + "";          var res2 = eval("5 + 10") + "";          document.write(res1);          document.write(res2);          

Read More

How to search and display the pathname part of the href attribute of an area with JavaScript?

Vrundesha Joshi
Vrundesha Joshi
Updated on 23-May-2020 177 Views

To get the pathname part of the href attribute of an area in JavaScript, use the pathname property.ExampleYou can try to run the following code to display the pathname part.                                                var x = document.getElementById("myarea").pathname;          document.write("Pathname: "+x);          

Read More

Execute a script when a mouse button is pressed down on an element in HTML?

Vrundesha Joshi
Vrundesha Joshi
Updated on 03-Mar-2020 394 Views

Use the onmousedown attribute to in HTML to execute a script when a mouse button is pressed down on an element.ExampleYou can try to run the following code to implement onmousedown attribute −                    This is demo heading.             Click above and then release.                function mouseDown() {             document.getElementById("myid").style.color = "yellow";          }          function mouseUp() {             document.getElementById("myid").style.color = "blue";          }          

Read More

C++ Standards Support in GCC

Vrundesha Joshi
Vrundesha Joshi
Updated on 11-Feb-2020 1K+ Views

GCC supports different dialects of C++, corresponding to the multiple published ISO standards. Which standard it implements can be selected using the -std= command-line option.C++98 − GCC has full support for the 1998 C++ standard as modified in 2003 and renamed to C++03 and some later defect reports.C++11 − GCC 4.8.1 was the first complete implementation of the 2011 C++ standard, previously known as C++0x.C++14 − GCC has full support for the latest revision of the C++ standard, which was published in 2014.C++17 − GCC has experimental support for the next revision of the C++ standard, which is expected to ...

Read More

How can I profile C++ code running in Linux?

Vrundesha Joshi
Vrundesha Joshi
Updated on 11-Feb-2020 1K+ Views

There are many great profiling tools for profiling C++ programs on Linux. The most widely used tool is Valgrind. It is a programming tool for memory debugging, memory leak detection, and profiling. You can use valgrind by passing the binary to it and setting the tool to callgrind. First generate the binary by compiling the program −$ g++ -o hello.cpp hello Now use valgrind to profile it: $ valgrind --tool=callgrind ./helloThis will generate a file called callgrind.out.x. You can read this file using a tool called kcachegrind.If you're using gcc, you can use the inbuilt profiling tool, gprof. You can ...

Read More
Showing 41–50 of 218 articles
« Prev 1 3 4 5 6 7 22 Next »
Advertisements