Jump to content
php.lv forumi

Vairākas valodas - vai jāinklūdo visur?


nezinis

Recommended Posts

Veidoju mājaslapu, kurai es varu jebkurā brīdī nomainīt valodu samainot tikai language failu.

Esmu izveidojis divus language failus - english.php un latvian.php, kuros esmu definējis atbilstošās konstantes. 

 

Lai izmantotu šīs konstantes, man manā ielogošanās failā ir jāizvada "_SUCCEFULLY_LOGGED_IN", bet protams viņš to konstanti pats nespēj atrast.

 

Vai man tagad ir jāinklūdo mans language fails visos php failos, kuros man tās konstantes ir vajadzīgas? Vai arī es to varu izdarīt vienā vietā un tad visi mani .php faili tam spēs piekļūt?

Edited by nezinis
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...