WEB170 » 10) Create a Pull-Quote for Your Site Using Custom Fields
Let’s say… I want to put a quote in my sidebar on my pages. But, I only want to put the quote in the sidebar if one exists. How would I do that? Use Custom Fields in your WordPress Site!
Requirements:
- Go to your “About” page and set up a custom field…
- First, if you don’t see your custom fields, go to your screen options and show them on your screen.
- Once you have turned them on… 1) fill in the name filed, 2) fill in the value field and 3) click add custom field.
- In your sidebar.php file, use an “if” statement to ask is the key exists using the Get Post Meta function.
- Write the markup to display your quote and place the value of custom filed’s key in an element.
- Give your quote a bit of style to make it look nice.
- I will check your Protosite’s “View” and “Code” links from your Client Staging Area according to the class Schedule (Spring) to review and grade.
This portion of the Premium Design Works website is written by Mike Sinkula for the Web Design & Development students at Seattle Central College and the Human Centered Design & Engineering students at the University of Washington.
10 Comments:
10) Create a Pull-Quote for Your Site Using Custom Fields
http://www.hanstorchid.com/taichi
https://github.com/learnerone/web170/tree/master/Taichi
11) Create a Pull-Quote for Your Site Using Custom Fields
I just styled the Pull-Guote, and resubmit it now.
http://www.graciebikes.com/web170/wordpress/
11) Create a Pull-Quote for Your Site Using Custom Fields
http://gloriazhang.com/web170/client/index.html
http://xukairong.net/web170/index.html
Hi Mike,
I tried debugging for pull-quote but there were no error logs regarding custom field :(
I did finish the custom field/feature images as well. Don’t forget to mark me off for that! thank you
http://alecmartin25.com/web170/web170-staging-area.html
webaff.net/web170/
This is now complete, and the code has been synced to GitHub.
http://lindese.com/web170/wordpress-sp16/about/
Dwayne
Trackbacks: