UP Assignment

You might also like

Download as pdf
Download as pdf
You are on page 1of 20
Unix Programmcing ane Roll No F = \ Explain Architedure of Uni 9 Aa the erain concept that unites all the vertons of Unix ia the bey | our hosics * ever! > laine | “the Keon i the heart ob the operating system, DF interads | uith dae hovdware and mest of the toske Lhe remoy rranagu | task scheduling and fk management: | + Shell + | the shell is the chlity shad proesier your requosts. When you Spe | | in & command ot yous terminal, the shell interprets the command | and calls the program that you woat «the shell user standard! | aw coy abl commands + C Shell, Bourne Shell, and Korn Shelk are the mast famous sheble which ove available with most of the Uns variate. ° Commands and Ublter 'r | | There axe yasloue Commands and utile, whidh gow. con make use ef | ie gout doy b doy achvitles « cps mv, cot ond guep ces one fw eromply of command: and uAlier. there are over 250 tandasd cornmnande phut numerous others povided ‘theough 3 paxky sofhwastes | All te commands come along with varus options, | * Fle end Does A the doit of Unix ix organiced cde ler All ler ave then ogiahed | inde diteetirten « Thoye abirevtor'en ave duethor owanived ints a tree-Lhe | | Sruduve called the Ailesy ster | al Ewplain dechner of Unin 2 £8) the Unlx operating syrtton hos vor fa Ahad make it powerful ‘verse platform. Some of the trey wy of Unix indade : 1+ Muldiusey; | Unix can be ured roultiple usere of the some hime. Thi * mack | | posible by the lemely which jer Ane rerourcer af the womputer syste, | euch ay memen and CPU tines and enturey thet each @b user’ provers | iu given 0 taiy share of these veounes. (+ Malitosking + Univ con run multiple prone ot the same ard time. A proces it | Lo hoxge program thal ie curmendly ‘running. the Kemel scheolule, the exeathon of there proteses so thal they can shose the CPU time. | . Portability r | Unix ie deigned to be poduble » meaning that it tan be oun on 0 \ vowel ob hossdevane plotiorme. thi is achiewed bi ating & Jaye! | orehitethre, where the diPhret layers ave independeat of the wedi hoadoore | + Robustness + | Chis 0. robust operating typen that cm withetard tytn dailne | This fs ochioved by uing’a voi of fedhetype,sush o» ever deon ond weeove ond by providing ° aysleen of le pormivons that helps to | | protect data tom unouthetred occen | Hgavehioul the ychen: ! | Univ wey 0 hierardvtal file sgrltmn where Flos are owganiced ine | tree-Lke shuchie. Thie malsey et cong te Bnd and manage file. | | + Shulls | The shell ik 0 pogrom tad Inferpech unr emmacde ard Hoods | with dhe kernel «There one many ditdevent shells available 5 ech with ite own eotre, and capability, | = ——— a Explain internal and edema commend in Unin 9 Tadra) Command Intemal Command: ove built-in funchons of the thell itrelf. art txeeuted dlivectty by the shell without the need fro seperate |) external progewn or exeudable Ale Trtemal commands are ueua lly pot Jot the shell’s Aindinably and are quailable 0% 1000 as you open a [Herminal seston Some conmnon examples of irdemat tommands incbude : |ecd - Und to change the curend vorking directo. secho - Disploys text ox variable tof the terminal. | isalior ~ Deller or iploys dione, Av cernmandl- i “export = Sele envisonmedt vartables fo the curvent session. in history ~ Diephaye a list of wecerty erecided commands. \ \Bcemal Commande + | Edema) Commands ove progoamt of exeedtables that one srpevotte rom the shell these commands are ot built inte the shelk At one stored | | seperade ler on the fle cqsteen- When gou tus on extemal Command) he shell decoder the exeudable filer by searching directories bited in te | PATH envitormend variable ond then entete it. Putemal command: con | | |e woaen in vss paring darquager Jthe C8 enor tan bl sop |Faoerss | | ’ cle. . j [as = Ude fes ond dene to the corent did "qr - Searches for patterne tr et fey, | scat - Concatenates and dicploys fle conaturts- | gee - The GNU Gongiley Gllechon fox compiling C, C++, and other | | __ Pagomaing largeng> = python - The Puthon Interpreter for running Betton serps. Ee File Syeken in Unin 9 B]eThe Unix le yuki tea hierarehieal fle system, where flee ove |ongontoed Goo vee he shuchire The root direchory » denoted by o Awwoad stash (/), is the top of the dree- All other divechoiy ond | Ble, one Contained within the mot dirwhny ov te subdiredrie, “The Unix Fle gy steen hor seven standard Ale ipa 1) Regulon Filey | Thee Bes craig data, such o» teat, images, and programss a) ‘Dircechoviey : | (Thee Ale contain other dlivedtovia ond Ales. 8 Syrmbobic dink s + Ther Riley poi to other Fler ov diveetoves. |) RIEO Special Alen || these les ove used fy inher prcen communication |) Glos speiot filer + | These Biles vrepwereat physical devices, such a harddnies ond obi be |v) Choaacer spa! Meo: | | thar Bly repent character devs, suth ox heyboons and menitio| || wi) Socket filer : these fle ore used for nrabwork communication, a a Eoub fle or dit in he Unix fle aysten hon © uniye name J ond a sd of permiatione The permivsfoas tort! Ree who wan Occern | the fle ov director and what hey can do wih 4. the Unix file system it & pomrhl ond versatile wey to organi ard | store data. Gt used bo wide variety of opto agen, rung | Unix, Linux, and enoeds- 5 eiplain vl editor 9 fifethe vi editor ts a text editor thot ie used in Unix ond Linux opting, | ytne: GU ho modal editor, which means thot it hos tivo modes ; | Command Mode | Dn Command Mode , ypu can ender commards te edit the tert. fox example, | you can use the ‘1? command to enter che ingert modes the Sd? [command 4 delle tee, and the 'w? command to write the changes | i te fle | fanaa Haas | fo Trert Mode, you con tipe tert into the Mle | athe vi edit is a pourrhl text eclitor that com be used) cto edit oy of tet files ic abo a very efeiont edbiby, and it can be used ty edt Loge files quit | ledlove ane Some of the boske commande of the vi editor > i of = Erber insert mode : | d =Delele the chanachey undey dhe cinsoe | | @ — White the changes fe the fi, v7 Qu the vi editor: There ore other commands available in the vi editor. You cand | enore abodt trem by reading che vi manuel fae To edit o tle with vi, you con use the following command t — vi filenome. qt | | jf ext abot ot Ble mnyhletd, you would ase the #ilbu'ag | vi met *|) Bile hardding udUhe, ave teh of commands that ane ured to mani Be and direchles in Univ» Some of the mast commer ale hardling julibte, incade: |e st the content of the cared” divedoayy you would use the | Ys? conmansl? | | iM le + To create a new directory coled ‘engi’, yee would use the ‘mbdiv’ command : [rtd eoydir _ “To veenove the emply directory Cong”, you would use the Sands” commard 2 Wendiy muydlir Te copy the fle Cenghle tat” + the diecboy ‘roydiv”, you would use sel ‘ep’ command : | ep ngfile-tut mys “ey scove the le ytlectat? te the dich "ry, you would se tray? command : my mytile tock i * To delete the file ‘rng hilectoct”, gu twould use the ten’ command,* wo creale the Ble ‘an erly file called ‘mye, you omild vse te | touch? eommond : SS F) Explain Seausty and file permissions 7 t Seeunily and fle pesmiions ove essertol oupeets of Unix- bared 9, perahing ston) |suth a» Linuc,Unix proviso robust and flexible systeen of le peveniscions ond| Foecess condal t ensure the searily of Ailey and directories | Bk Pevenitslons Vain tues a three —Hoved —permisiony syslen fox Ailes ancl divesbriey, divided | | todo three tay f pen eg S Owner + The user who knows and own the fler o1 drectores. | | ae’ A grup of users who share acct to the file ov diveclry. | © Othews + All other user on the system, | Eauh cocbegory ton howe 3 ‘type of prrerieclons-2 [Read Gr): Allows the Ale ov dixechny to be viewed ov ead | ug (0) 5 Allow enodBeations the Ale ov dliveubny, Fncludlng creasing | or delekng Piles woithio 0 divechor «Enewte (0) ¢ Allows ce tile to be eneested a © program ov sept Charging Permissions + You com charge file permistone using the tehmod ? cates -forexirgle | to give veod, waite, and exeude permiscionc tle the owner oh o Ale: Ged ttn pet g % cremoye woe ptrmiuions dam the gr cand others : | ehmod go-w eng hlectact To choage he owrership We can use “chown! Command’ fartnanple, | I | chown newuser nytt — and velodie 2 A|| Absolute Mode; GH usey octal cumberc to vepresend He permissions. The octal number dr cath ad of permtislonr ts the sum of the peemmitiions ov each bit For example, the otal number 755 vepresedts the following permisions ; | «Owner permissions + ead, usrite , and exeuce. )* ‘Group permissions : ead and exeude. || « Other pesmistions + read [the dellewing aiden + Chrood ottol_aumber flename. lew example, chmod 455 frletat |Reladive Motled : |? usec the “and (= " operatens ty add ev memove perrmisfons. The ‘+" operator adds the tpecifted permisiont do the wrrrendt permisions, and |e "=" operator remover the speUied permicctors trom the cument permis 1 td the permiutone fy a fle ov direuty in vrelodive mode, you use the | Aallowing syrtan: (theod +)- permisionList Filename [for ecampk, the Allowing command addi Hye toad” permiions foy the ovnts jos ‘the Pexeashe? permision dy the grup to the dle “Blett? : | choad aren Aletat | 11% eck the pesmintons doy 0 Ale or dirdoy in obiabitely emode, you us sock dad Ehvad Goma Py ae permissions a By bali abot | | I | used by terminates suspend, or rourne the procens. The *ball” tommangl Diss obowk provene whl! 9 Thee ave many proce utilities in Unis, bet some of the most tommon © include? «ps - The 'ps' Command con be used to List all the Tunaing processes | ov ty bist only speife proces. The odpet of the *p87 commana) can be customized by using aptions stop the top’ command displays 0 coninumuely updated dist of dhe ly processes y sorted by PU usoge, The ‘top’ tammand can also be used | to bill suspend, or sume provone | skill The “hI” command sends 0 signal ba procors «The signal can be an alio be ured 40 tend a eignal 4 oll proves auned by a specie | user [eee ~The "nice? command changes the priority of & pocos-“he priovty cn be used to make a pavers gun mote slowly or more qpichly “the ‘nice! command Cor alo be useol t sot the default priority Av ealy created | processes: | Uinshup— the ‘nobip? command allnws 0 prows to wntinue uning even obey | | the teyminal & closed. The ‘nohup” command is oft used trun | | background prone. sealt ~The tual! command waits tor a procers do Ainich runningsThe “won't? Command can be used to enrure that o peoeen har niche Tarnng before amdinuiag astth ather tosh. | | 10- t0-| Disa * aled dic ues § AWDree adbbher ae a cet of tool thot con be wed to manage dishs and) | pouktone in Unis Some of the east common disk utilite include s fedt ~The ‘dl? command disploys she dik space uroge tr all mowafed Hier. the apd of the ‘dP corimand con be culomived by using options: “du The “du” command dliplags dhe dibs spoce usoge ov dlivedbry or Ble the oudpul of the do’ command can be custorired by wing ophins embts The ‘rkes? command eveatey 0 new Alesystem on a disk partition «The! Aleaysteen yr con be specided ushy an option | mount - the trait” command mounds a Playstern to @ direcheny« “he i ign can be mounted read-only or tead-unite. i summourt - The tunmount? command unmeudts a 4 Nesystere trom a. drredony, stdich — “the “Pick? command can be used crtake, deleh, ond vester | poutitions on a dish. The partition: ton be created a» pepe | ox Jogi) patton jrdd - the ‘dd’ Command can be used to copy, sconvert, and create Filer. the dd? command con alo be ured to eneofe a dak iemage, sfrck — the “Pack? command can be used do cheels ond repair fleyttens. | The Pleugshon tan be checked for exrou ard repaired it mecentady | | J ss command’ in Unin ave Ganka) fy contouring ond troubleshooting ndwwork connechone Thee command: allow you to indmack with ndusorh indewtece cheek nébioork coctgurations, drognose network true, and manage nebo Services: Here ame some common nebwarking cormmaret i Unix t sHonty — the “fear” command i used ty conkgare ard diploy informebon | abot netiows trdevfaces» Gt ton be useo! to enable or dioble | icterfoces, assign TP oddveres and check the sah of nabwodle tndher dace - rp ~The ‘ip? command i more prot ard vewatile tool for conhprng ntucrk | indesdacer, ute, and tunnel . Gt can replace many funchonalities of “eonkg® ard *youte’. | *ying - the ¢ Pg’ command ke used to tet netisork connechivi by send feet, echo wreqpasts to 0 daagel hod O's © Aiadarenta) Tool to nehivosk | ‘troablechooting. i strocered /botspath - The Hoacwoutt” and ‘hossped? command one usd to trots tne woukt token by gaskets 4oweach dtnaton Thy thos each Hop along she pa. | snetsat — the tadsat’ eommant diplaye ab stb, iodading achive | network Connectors, eroubing dobler, ond tnderface stottsties. [ase— the ‘3s" command ie similar ts tnelaad’ but provider more detailed | sabpmedtin abeit oblitth séehels dnd conoachine . up/down — These commands are used to manually boring up ( ‘up? oO boring down (ifdlown’) network intedace. “They ane offen used| | inthit scripts or for temperooy inferface management |onetretad) - tlehot i a venadtile nchorking wcility Hat com oct 05 0. sing nebaork cet or sever DF von be uses) -for varios foals Like po sconnira,hroniferring placts, are debugging nélivark servicer Unit - Gwe | Ny] Wrike about syatache chonocer'sties in i By PHP is 0 widely used seniph foy web developmedd on Unix basa systems Whun rc come to hee choroctoricHes in PHP on Unis, dere ate | several one 4 to consider + |) cose Sensi vi | PHP ts eare- wensifive This means that variable name, function names, au | dos: names must be spelled with the cored capitobization, 1D Semicolons : | Go PHP, stobemedh must be erminofed with a semicolon ('5?) Failure | do so will gerult in a eyritax enor. 1h) Comnmesths = | PHP supports both siogle - Line comments (J) ond multi-line comments (/er/] Ny) Variable > PHP vawable stort with o dollor sign ($) followed bay He variable name: Voridles ramet: are tor-sensifive and can contuin letters numbers , ard underscores bud must stot with a letter or underscore, } 7 Date Types = | PHP supports vorious data. “yper, including integers, Flacting poldt- numbers, shy | arrays, ard rare «Unlike some Lorguoges PHP wey dynamn'e ‘typing 1 80 you | don't need to declare the datadpe enplilly. | | Soa con be enclosed in sy le quurtes (1) of dosble opots (°)-Varables Inctk | double-qyasted shiogy will be ta, wWhle single - quot stings heat ever os a Lteral y a 4 vi) Coneatenation ; To concafenale stings, you can ure He * . ? operator i) nog s+ tHe support bot trdeved amagt and onsocistive army! -Buened ovrays me qurene fndives , ualile octociative amen We named keep Fe bed ie in PHP? | Ad) To PHP tee ove several primitive dette types used to reprorend bee values. there | | prievtive date type | in Pie, which can be used on Unix ~ bored systems o vel oo oder platforms tnelude 1) Tidegey 3 | fo Iodeger Is 0 whole number without o eee point - Su PIP, adage can be veprserted in decimal, hexodesinal (with & "Ox" pretin), or othal (wits Yo nobation. 4) Flood» A Hoat represents eo number with a decimal point « Floads con alto be coprened | in suentthe notation, i) Shing + A shing fe a sequence of charouters tevolved at endesed in cithey stage to ov double qpoted (° ") PHP supports a wate range of wing monipudestion | Anchors: | iv) Qoolean + | | A boolean ~eprestats o due ov abe value vy) NULL Spull’ fa spout valine dhet reprerents o variable with po vabse or 0 rence Volue, | vi) Resource + | Arernurce ie a speciol ty of data wed ty seprosent edtonal reoures, cuth a» file hordtes ov dalabore connection Rerources are ‘yplally cxatkd and managed by Aandhons oudsisle pip. villdnog + | An array so venahle dita type tn PHP Thad can hald eractiple values Pi | tak supports tndened , accoedcte ond muthiliment ional ora lit) Object © PAP i an objest ~orietd Jonguoge sond gor con dedne custo clasies to | | | probe isleat create objects. | Explain about opredions and exprenions In PHP Operations ond expresstone aye the building blochs of PHP pragnauns. Operations are used ty pebym achons of dita, while exprenions ove used to combine |data and operation: to pmduce 0 value. | PHP supports 0 vesiely of operations, includig | oArithmebe Operations + | Thee operation: are used to perm mathematical operations on numbers, such of | addition, subbovhony rnultipteaton, and dition: . Aasigrnend Operations + \ “these operotion: ane used t astign values fo vam'able, [+ Genpanttion Operators > | Thor optratane ave utd compare teluts ond detemine if shy ate eqpal | greades than, leer than, ov not equal U Legis Opera + There operabon are uscd te combine lagcal valucry Suth os TRUE end FALSE. ll. oy Operations ' There operations ove used to moripulote shings such or conuslenation, tomponth ond searching. | + Aro Sperochons : | Thee operations are wed fo monipulok arrays, gush os adding , vemning, and searching yr elemote | [Expruions am made up of varlalle, optrador, and Lioal veluts. Te value of lan exprurion 4 determined by dhe oder oF operation: ond the bpe of de Operands: Gaanpless |*$a+$b t adde tre values of vovobes $0 ond $b- Ve bax =t0 4 assigns tHe value (0 fo tke vanoble $ [+ Pye des compos He veluas of te variables $y and $2 and determines it i ty tan thon $e: || «Helle, world "2 thle evproston tk a. otra Literal, 4) Explain about oudput stodementa in RHP 2 | £2]To PHP, you con use Vorbur techniques to guenie olpud ov diiploy Sedorenechln | to dhe user ov clit browsers Here ave some common ways to create output | stodemends in PHPS i) echo Stodement j | — |The “echo! stdement is one of the mort common meltods te disploy odpud | in PHP «Gt can output one or more sting ond exprassions Peas Statement + |The ‘peinh? stodemedt & similar fo ‘echo’ bet con only output one vals | cto Ame Gt rims (47 Hf cuctershal and “alte” on dailve, ” Usieg 4H Togs with PHP > i) i You con diveatly Taulade HTML win PHP code This ie useful by generoy | HIME Corded remitally | i) Merde ard Nowdor + | | Alewedee ond Nowder ore mettods fot opullig Jorger blochs of dent wolile | proveruing whitespace | \? pridit) Ruretion | |The” paat# OO" Lanchon allows you te formot ond pant 0 Shing wwidh plocehabls| v) vor=duimp() and pret Rarchons > | | these Rincon ave ured or dehagging and Iripeshing de eonttrte of vartahley ond data ctychney: wii) Headers ond Reckiveats 5 You tar use "headert)? dunchlon to send HITP headers, whth van be wl | for valireds or thay weal tyes | win) Ton Oudput | When contig wih APTS oy ATAX, yor con use { json- encoders” +h outpd data os Jeon } cahes >| Esplin bout oop in mHPD ||Amoys to PHP ane veratile and Merible dota shuchires used to stove collechons of | data. PAP cuppnts Semal type of arey® including indened anayt » osecictive | ovoge yond mulfdimensonal avreyt- Hew ean overviews of cach type 0 Trdered Arrays: I Erdened Arrays oxt Lisl of values ebpred with numere tebe soi too 0 and | treating seqpsarkillg« “hay ave similar to heditbnal arrays in mony prgromng | | org ak) Auodative Avaya | Aned alive emoys ute tamed keys (shrugs) indead of numeric indices They ollow | you te oxoushe yes th apecte hapsrmaling Ht toster fe ebeue dala | Ae] MubHdtmenstonal arrays Ont omer win ovrays ey ollow yoo te repraed enore| comple data bude, Guth a tables or madiers, tig ond alg etre; You con add ox med ty elements in On oray using asigarnents y Counting Elements '; You can ad court th number of elements in an ornay using He ‘coud O" eda. 9 Loxpg trough Horoys || You tan use loops Lhe “foreach? ta Lirade Hrough ory s ||vie) Arrony Funchions 5 | par pies emay builtin Lincs or working ohh ers, suh os ‘ory pal | one. pop), ‘array. mage", ard "array -sbice()’ » among oken, iy) Sorhig -Ammoys + | You con sort onraye usiag Aanchions lke sort)’, Sreortt)’, “asortt)’, ond | “ksortt)’ do ae elements in varlous ovdene. \ | AY)To PHP, many -Ainettons ae used suth as builtin Ainchon and user-dedned | |-Shing Furchbos ||eNumeric Funchons + Dicuss abut finchon io PHP? jfandions: Boch ond every izstiin hes i own Rinchonabity ond propertes A harchi te tek of statemeds writen in dhe prgoam ddd con be used mulhiple -bimes ty [the code angute needed. A danchon call is vaqpired to mab eveoste He | shabomede unten tnside the fercton, “Tyre of Badane fo PAP ie HP nciny tio inchon one ned by abe programmes. They one | |) Uwe Detlned + | thee functions ou used whe tte developer or Prograreney has le exeerte eds ot logic of tode. there tindiom ort detned using she heqword Aunchon and | indde the Auncion,"o eet of sdosemonts wall be urttlen do exoushe ct when | | Auction Cal cewure. “the Ainchon call con be made by just simply eltng cthe Anton Uke furchonnamel) , od te Lach will at eneeralecd, | But -in + | [then Rinchoor provide uc with builf in Library Amdions: RHP provides thaye Aeactins | | fn the installation p je Heal? whith makes thi Longuoge more power | Fond useful use the propestion of the iechon we just need fa coll the Rurch Jwhereer tequed to felth He derived rest These are many built ta Ainchtons used in PHP cuch a» Dede, Nurnenie, Shy ek There Ruchone have 0. predetined Lunctinality in PHP ta work wotth strings. PHP hos various sting functions suth os skpost) , strnempl) « straevt), ahden()- sDote Finction Thee tindions ore predefined Anchonaliy tn PHP where the format te a UNE dot. ard Hone whds is a Auman-readable brmad There tndhon hove Her own predebned lagic provided by PHP whih ts used for une cperations « GF ull rehire result esther fn Boolean fovm or tn the qumerie im | Some of the rumeric funchone tnelude is-runbert), number toms) ,mucd , ek. == a | Explain podteve morlching in PHP? | AF) Pattern roalhing In PHP is ‘typically alone using regulon expronsions HIP. provi “eeveal funchbos and operators: for werldng whh regular exprenions to tenmh, | imalehy and rronipulate rings bored on specid'e patterns. Here ave some key tool | | boy pata emacthing in PHP: | [DRegelem Speulon Fanalbes + | Bieg-mmadh() This Andon cheaks HP 0. patteve existing to a ghring | reegemebchaall td tah Rndton fick all occurence of & peffon to alg | | pimg replace) > Dt replaces all occurrences of 0 patleyn with a specified replocoront spreg— 9pbtu + Splits o Shing jets on arvoy of subs s based on» pattern. 1°) Regulan Expr Operators | The ‘20 opnatr ir used in Combinodion with ‘preg — mad)” ay other vege Aundiont do moth @ pattern ogainsh a shige #) Captustag Goups You tan use posertherts to create caphoring groups in epuln exprorsions. Capt groups allow you ts ewtracl specife ports of the mashed hing: ¥) Volidolion and Dota fxbaction + | Regular expressions ove Commonly used for dorks such ay validating email addres, URLs, dots ond endraching lite. from studured feat, Ihe posing | log Kiley. |) Regular Exprasion logs = Flags can be added te vegulos expressions t modify teig behaviouw: | @| ide abatt form hardbing tn PHP 2° PUP form Handling + Heide ton coedte and use forms in PHP, T get dorm dota, we need te use PHP eupuglolals $ GET and $_fost: the Foren + be get o post. T , | Rie dat futet, eect domaciten nT oe eet al requust ts visible on the URL browser so it is not secuved+ You con send Grntted amouck of dats Hough geb request [PHP Post Fan's - fost repent is widely weed to submit fom stat hove Loge amount of dats | such oy file upload » image upload, dagin teen, vegisrahion form ek: [the date posed ‘through post vequst is not visible on the URL byouxer 80 Ht is Secured You can send forge amour of dota tervugh post request Gs) site bout files in PHP? Ay) PUP Ble system allows ug 4 create ‘le, sread Atk Uine byline peed Sle charac by chorachey , wove le, oppend Pe, delete le, and lore Ale. The PHP fopent) “function te ued tr opin a tile, “felowe ("is used & chose an open fle poiehy- | PHP Read file “fa thpPrtad()” Aundtn te used te vead dhe condect of He Ales cccephe 2 ongurmenks + wverouree ond Site. wee. | | PHP Uadde file + | Pony” ie usd sh witle cob of ch stig tale file [tp Delete ley “unbink(y’ te used ste delele tte cle. Dicuss aboot cookies and sestion hacking» Coolest PHP supports the concept of cookies » Cooke is seh using te “setcookiet) ” functor. This incon toler ia one or moe paxametys: The Bret poramely is dhe Wookie name which i erandatong and is given or 0 shing- ‘the | second poromehy is “oue” which & uted dy define 0 taolies The third | pouamebey fe the explanation inne fn Seconds. the defout value of || expixation time is zeve which is ued to spre thot the Colsie is ||deshoyed ad te end of uurrent session, tol & | Session Toacking PHP ho» seetions array whith con be used to Stove informahon about | proviows vequats of 0 client dumag a Session: fm PHP seasion TD ts [the seston ig hardled i PHP Usleg “seston. stat)” incon ehh doer | |no poromedis. he fret call “selon state heathen cause & seruiba ID) | the “$_SEss20N” away which sores ony sesslon voriabley ond Yelr Ilrelue, that uvre registered eosliey in the Sesion, | i | i ceald, ot hed 43 He trderna) value to identity He censton: The seaion || “asm fe chored on the Sever wwhereay the Cookie te shred on the chien «| lo be creoted and subrenuiact calls ta “seston. stoatcs” indion srebteves | | | 1 HH

You might also like