Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. Web Development
  3. where to place JavaScript

where to place JavaScript

Scheduled Pinned Locked Moved Web Development
javajavascriptphptoolsquestion
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • H Offline
    H Offline
    hrishi321
    wrote on last edited by
    #1

    Hello All, I am New to php :) I wanted to modularize my pages nicely.. Found a method to divide the page into different php file and include them in the main page.. Is it a good method? . . If so, I am not getting where to put my java-script code. . Usually I put them in the header of the page or a different file and set up the link in the header... But now, if I want to call a method from a subdivided php file, do I have to write the method in the same file, or I can put all the method in the main page, just like usual? Please feel free to point me out if I am lacking some other basic concept :) thanks Hrishi

    D 1 Reply Last reply
    0
    • H hrishi321

      Hello All, I am New to php :) I wanted to modularize my pages nicely.. Found a method to divide the page into different php file and include them in the main page.. Is it a good method? . . If so, I am not getting where to put my java-script code. . Usually I put them in the header of the page or a different file and set up the link in the header... But now, if I want to call a method from a subdivided php file, do I have to write the method in the same file, or I can put all the method in the main page, just like usual? Please feel free to point me out if I am lacking some other basic concept :) thanks Hrishi

      D Offline
      D Offline
      dusty_dex
      wrote on last edited by
      #2

      AFAIK, if you're using Microsoft IIS you can add php interpreter, and that way you can mix php, jscript and vbscript. With full access to functions/variables in either. (within the same ASP file) Access to functions located in other files can be achieved with *includes* directives, which load the external file into the current web server code.

      Q. Hey man! have you sorted out the finite soup machine? A. Why yes, it's celery or tomato.

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups