473,386 Members | 1,621 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Make the title of post it's link.

Below is a code in which title of post is displayed as link for opening the whole post, it works fine when using this way
Expand|Select|Wrap|Line Numbers
  1. <?php 
  2.  // some code to get title and other stuff from db
  3.  
  4.  echo "<h2><a href='blog.php?blogId=" . $row['blogs_id'] . "'>$title</a></h2>";
  5. ?>
  6.  
but now I have made some changes in my code and for that changes to take effect I have to call title by row like this
Expand|Select|Wrap|Line Numbers
  1. <h2><?php echo $row['title']; ?></h2>
so I want to know he right way in which I can make the title of post a link means I want to add
Expand|Select|Wrap|Line Numbers
  1. <a href='blog.php?blogId=" . $row['blogs_id'] . "'
to
Expand|Select|Wrap|Line Numbers
  1. <h2><?php echo $row['title']; ?></h2>
Oct 13 '15 #1
0 898

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: Acorn Tutors | last post by:
Hi folks, what I would like to do is to store the name of a link, such as link1.php in a field, lets say the field is called Favoritelinks, in a database as a bit of text. Then, on a logged in...
3
by: Steven Scaife | last post by:
I have a search page with upteen boxes that they can choose to fill out and my second page gets the values and passes them to a stored procedure which builds the SQL string and returns the...
1
by: futurepy | last post by:
My question is in the following page: http://www.pinyinology.com/learning/blinking_link.html Thanks.
2
by: Roman Ziak | last post by:
Is there somewhere a coherent example or available production code for something similar to intelliTXT: http://www.javaworld.com/javaworld/jw-11-2001/jw-1121-iw-jsharp.html Point on the...
3
by: wolfing1 | last post by:
In several of my pages I need to show an area with a background image and HTML text in certain places. The restrictions I have is that I can't use javascript or CSS positioning like 'float', so I...
2
by: rup | last post by:
Hello, This is my first application on socket programming in vc++. I am facing problem that how to make connection to server, & make GET/POST request by HTTP. Please help me. Its urgent.......
0
drhowarddrfine
by: drhowarddrfine | last post by:
If you need help solving problems with your web page or site, it's difficult to visualize the problem without the actual markup. A link to an online web site is best because we don't need to...
3
by: Andrej Tv | last post by:
Hi. I'm having troubles to come up with a way to assign an object's method to a DOM-node created by the object without hardcoding object's name. For example: function currancySwitcher(){ ...
2
by: smileyc | last post by:
Hi. I am using visual studio 8, using vb.net. I am trying without success to make a post request to a web form as shown below. <?xml version="1.0" encoding="UTF-8"?><postBetOrder...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.