I am importing a library into a script that is being used in a php document, but for the script to run, I need to import a library that is rather large. Is it possible to permanently import the library so I do not need to load it up each time I use the script? Any other workarounds?

You can create a dummy script and keep it running endlessly,
and your library will be always in memory, ready to be used by other scripts;
the dummy script:

import my_library
while 1:
    pass

`

That isn't going to cause problems for the server?

Definitely Not
Though it would be better:

import my_library

raw_input()

This doesn't seem to be working.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.