Snaip3Rs Posted October 20, 2010 Report Share Posted October 20, 2010 Domājat noteikti pēc virsraksta ka nemāku php ielikt iekš html! Bet tas ir maldīgi zinu, kad kādreiz biju taisījis tādu lietu kā ir garš php fails un negribas visu to atkārtot kā lai izvada no tā garā koda piemēram vienu daļu sakuma html kodam otru daļu vidu un trešo lejā! piemēram starp <h><h> gribu ielikt $player lai no lielā koda izvada player niku uz to html kodu! Quote Link to comment Share on other sites More sharing options...
mefisto Posted October 20, 2010 Report Share Posted October 20, 2010 Vārdi teikums secība ir sākas pieturzīmes saprast nav burti lielie grūti ? Quote Link to comment Share on other sites More sharing options...
codez Posted October 21, 2010 Report Share Posted October 21, 2010 MVC Quote Link to comment Share on other sites More sharing options...
marrtins Posted October 21, 2010 Report Share Posted October 21, 2010 mefisto :D Quote Link to comment Share on other sites More sharing options...
Roberts.R Posted October 22, 2010 Report Share Posted October 22, 2010 Bļāviens, google translate nestrādā, nevaru iztulkot tekstu :( Quote Link to comment Share on other sites More sharing options...
Леший Posted October 22, 2010 Report Share Posted October 22, 2010 Bļāviens, google translate nestrādā, nevaru iztulkot tekstu :( Strādā Quote Link to comment Share on other sites More sharing options...
Maaren Posted October 22, 2010 Report Share Posted October 22, 2010 Es bez iekšām.. :D Quote Link to comment Share on other sites More sharing options...
Mr.Key Posted October 22, 2010 Report Share Posted October 22, 2010 Jēziņ... Quote Link to comment Share on other sites More sharing options...
snach15 Posted October 23, 2010 Report Share Posted October 23, 2010 takā esmu iesācējs laikam sapratu :D <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title></title> </head> <body> tavi html kodi <? print "php kodi"; ?> citi html kodi <? print "citi php kodi"; ?> vel citi html kodi <? print "vel citi php kodi"; ?> </body> </html> Quote Link to comment Share on other sites More sharing options...
daGrevis Posted October 23, 2010 Report Share Posted October 23, 2010 <? ...uz... <?php Quote Link to comment Share on other sites More sharing options...
101111 Posted October 23, 2010 Report Share Posted October 23, 2010 daGrevis, tā darīt nav obligāti. Īso php tagu lietošana nedaudz uzlabo koda lasāmību un parasti nav jēgas tos neizmantot. Quote Link to comment Share on other sites More sharing options...
marcis Posted October 23, 2010 Report Share Posted October 23, 2010 @101111 tas ir tāds pats reliģijas jautājums kā par koda noslēgšanu ar "?>" vai nē (tas gan neattiecas uz templeišiem). Quote Link to comment Share on other sites More sharing options...
daGrevis Posted October 23, 2010 Report Share Posted October 23, 2010 Bībelē manuālī/dokumentācijā ir rakstīts... 1) Koda gabalos, kuros nav HTML, bet ir tikai PHP - nav jānoslēdz kods ar ?>; 2) Ir jāizmanto <?php, jo develop stadijā viss kas var atgadīties (arī mainīties serveri), production stadijā varam elementāri find->replace ar <?. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.