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

  • SEARCH
  • Home
  • 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 8312005
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T20:00:47+00:00 2026-06-08T20:00:47+00:00

I have been working some time on this and I can’t find the solution

  • 0

I have been working some time on this and I can’t find the solution ( if there is any ).

So the question: Is there a way to do an svn update request via HTML web form?

I have tested multiple web-based SVN clients ( including building my own ), but they all lack the possibility to do an update.

I understand that this is an issue with the user permission that PHP uses, but even if I set all files on my system to 777 ( tried it on a virtual machine ), there still is no way I can archive it.

Anyone has some experience on this?

Thank you already.

I also went over all the directories and set owner to Everyone with full access. Now there can’t be a permission issue … I think.

Last edit:
It seems I can’t execute the SVN if the script file is not in the root directory of the svn directory. The final code now looks like this: http://codepad.org/Kb2K8e6m

  • 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-06-08T20:00:49+00:00Added an answer on June 8, 2026 at 8:00 pm

    The following function should more or less do it for you. It also prints out:

    1. The exact command it is executing in shell
    2. The output of the command (including errors) so that it can also be debugged.

    function updatesvn() {
    
        if ( isset($_POST) ) {
    
            //Get svn username and password from request parameters
    
            $username = <your_svn_username>;
            $password = <your_svn_password>;
    
            //Get version number to move to
            $values = $_POST;
            $version = $values['revision'];
    
            //validate version number
    
            //Path where you have checked out your project
            $rpath = '/var/www/myproj';
    
            //Command to svn update
            $cmd = "cd $rpath; svn cleanup; svn --non-interactive --username $username --password $password update -r $version 2>&1";
    
            echo $cmd;
            $out = shell_exec($cmd);
    
            echo $out;
        }
    }
    

    EDIT: Beware of security loopholes in this code. I have simplified it here. We had used it in one of our applications where a user reaching this point was pre-authenticated as an Admin user of the web application. In addition this code was executed in an MVC framework where validations on input were done in central places before executing an action in a controller.

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

Sidebar

Related Questions

I have been working on this problem for quite some time and can't figure
I have been working on this for some time now and just cant quite
I have been working on this for some time. The script does work and
Ok I have been working on this gallery for some time and I keep
I have been working in C# for quite some time but come around this
Ok I have been working on this feature for some time now and it
I have one web application which I have been working for some time.I am
I have been working in C++ for some time now, but I am unsure
I have been working on a project for some time now, and I decided
I've been working on a PHProxy server for some time (you can see my

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.