Hello Brothers, CodeIgniter ke part-6 me aapaka swagat hai. Aaj ham home page ka thoda kam karlete hai kya bolate ho. dosto ek help chahiye aapki muje thoda confusion horaha ki konsa project shuru kare ham. eccomerce ya social media ka jaise fb. yaa fir blog banaye post comment. blog banate hai kya bolate ho aajkal trend me bhi hai. Aap muje comment karke jarur bataye please.
Chalo aaj ham home page ke function hide or show ka kam karte hai. jaise user login hai to hame register or login hide karke logout dikhana padega. waise hi login nahi hai to logout chupana padega hai na. or user ka name bhi dikhayenge database se nikal ke header me corner pe, jaise sab sites me hota hai.
Dekho abhi sab visible hai.
show hide ke liye ham session ka use karenge. hamane login or register ke time id store ki thi na? wahi use karna hai if else statement me. agar id hai to logout dikhao or nahi hai to login register. simple hai na.
bus itana karna hai home me kam hojayega. kuch doubt hai aap muje comment kar sakte hai. chaliye ab name display karate hai. isake liye hame controller me jana padega. per hame header me hi dikhana or baki sab page pe bhi dikhana hai to her function me use call karna padega. isaliye ham header me hi database call karlete hai short me. or ham ek or icon style bhi add karenge font awesome isake bare me to pata hoga? ye bhi bahut mast chiz hai. her type ke icon mill jate hai yeha bus hame link stysheet cdn add karna hai. ye CDN link hai online kam karta hai. aap agar ise ofline use karna chahte hai to bhi add kar sakte hai download karke.
For Offline Font Awesome
friends, aapko font awesome downlod karke apane project me dall de or fir uska path upart your path to me dalde fir ye offline bhi kam karega. waise online bhi achha hi chalta hai. dekho hide show or user name display karane ka kam hogaya hai dosto or mene username ke aage icon bhi display karaya hai.
chalo ab ham register controller me logout function bana dete hai.
Register Controller
or dosto route php me ye kam bhi karna padega yaad hai na link short karne ka route php config folder me jo hai
hogaya log out bhi doston.
header php Views
dosto chaliye aaj ke liye itana hi. aapko kuch bhi doubt ho. kuch bhi help chahiye aap muje comment kar sakte hai.
happy coding