Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6153207
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T20:03:21+00:00 2026-05-23T20:03:21+00:00

On my php page I have this exec function converting pdf to swf exec(‘C:\\Program

  • 0

On my php page

I have this exec function converting pdf to swf

exec(‘”C:\\Program
Files\\SWFTools\\pdf2swf.exe”
“C:\\Program
Files\\xampp\\htdocs\\system\\logs\\reports\\temp\\sample.pdf”
-o “C:\\Program Files\\xampp\\htdocs\\system\\logs\\reports\\temp\\sample.swf”
-f -T 9 -t -s storeallcharacters’);

on my localhost it works but whenever I put that function on another server let’s say http://192.168.0.2:8888/system/ it doesn’t convert the pdf at all…

Please help me get through this…

thanks

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T20:03:22+00:00Added an answer on May 23, 2026 at 8:03 pm

    Ok I already resolved my problem here. for others to know what I’ve done;

    here’s my code

    // First, I create a new .bat file using fopen
    
    $ourFileName = "C:\\FILE\\PATH\\TO\\sample.bat";
    $ourFileHandle = fopen($ourFileName, 'w') or die("can't open file");
    
    // Then write the content in it with your pdf2swf.exe syntax to convert from PDF to SWF
    
    fwrite($ourFileHandle, '"C:\\Program Files\\SWFTools\\pdf2swf.exe" "C:\\FILE\\PATH\\TO\\sample.pdf" -o "C:\\FILE\\PATH\\TO\\sample.swf" -f -T 9 -t -s storeallcharacters');
    
    // Close the handle
    fclose($ourFileHandle);
    
    // After all above executed successfully, we now run the newly created .bat file using PHP exec() function.
    
    exec('"C:\\FILE\\PATH\\TO\\sample.bat"');
    

    I don’t know if there are any other way to do this but this works for me

    using Windows Server 2003 with Apache 2 and PHP 5.2

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

i have tried this code to redirect a php page.but it s not working
I have a site with URLs like this: http://domain.co.uk/subdir/page.php I have redesigned the site
I have a page that is accessed via a URL like this: http://power-coder.net/Test/something.php?id=3#Page1 I
I have a web page coded in PHP. This page is for posting a
I have a file named gcc.exe and I have a php page... I want
I have a php file that calls exec() on a c++ exe.When the .exe
I have a php page and i have some javascript code to have a
When showing data from a mysql table on an php page does it have
I have a php page that displays rows from a mysql db as a
I have a particular PHP page that, for various reasons, needs to save ~200

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.