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 8989499
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T22:16:29+00:00 2026-06-15T22:16:29+00:00

oh boy… Hey guys hope all is well. I’m an iphone/ipad programmer, wanting to

  • 0

oh boy… Hey guys hope all is well.
I’m an iphone/ipad programmer, wanting to create a webservice with a few methods that I could then send json requests to the webservice and make it all jolly.

I’m currently trying to create a web service. This is my host: justhost.com. I understand I wont be able to setup any sort of .net framework since its all linux. I then was told i could however setup a web service with slim or epiphany. Both of which I’ve been told shouldn’t take long at all to setup. 5 mins max? I have however spent the last 2 days trying to make things work with little success.

I stuck with Slim since, in my opinion, it has an easier setup compared with epiphany. I now am testing an hello world example so that I am then able to write something like this in my webpage….

testing.mysite.com/hello/pk

but I’m just getting blank pages. im assuming that my .htaccess file must be correct for any url i write in the address bar with a prefix of my site to not throw a incorrect error page.

This is what my folder directory looks like atm:

enter image description here

And i’ve inserted the .htaccess file that was provided by the Slim framework.

What else do i need to do to make this work. what am i missing. I hope someone can help me with this.

UPDATE 1

This is the error im receiving.. Parse error: syntax error, unexpected T_FUNCTION in /home1/dholnot1/public_html/testing/index.php on line 8 I then removed the semi colon at the end of the require statement and that changed the error to this: Parse error: syntax error, unexpected T_VARIABLE in /home1/dholnot1/public_html/testing/index.php on line 5

UPDATE 2

This is my code:

<?php

    require 'Slim/Slim.php';

    $app = new \Slim\Slim();

    //GET route
    $app->get('/hello/:name', function ($name) {
        echo "Hello, $name";
    });

    //POST route
    $app->post('/person', function () {
        //Create new Person
    });

    //PUT route
    $app->put('/person/:id', function ($id) {
        //Update Person identified by $id
    });

    //DELETE route
    $app->delete('/person/:id', function ($id) {
        //Delete Person identified by $id
    });     


    $app->run();
?>

UPDATE 3

I have upgraded php configuration to PHP Version 5.3.18
which means anonymous functions will work now.

this is the new error im getting:
Fatal error: Class ‘Slim\Log’ not found in /home1/dholnot1/public_html/testing/Slim/Slim.php on line 242

i’ve checked in the slim.php file at line 242 and it reads this:

‘log.level’ => \Slim\Log::DEBUG,

  • 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-15T22:16:31+00:00Added an answer on June 15, 2026 at 10:16 pm

    Use the code below:

    require 'Slim/Slim.php';
    \Slim\Slim::registerAutoloader();
    
    $app = new \Slim\Slim();
    
    //GET route
    $app->get('/hello/:name', function ($name) {
        echo "Hello, $name";
    });
    
    ...
    
    
    $app->run();
    
    • Slim uses namespaces, so you must use $app = new \Slim\Slim()
    • Use the autoloader to let Slim handle it’s internal dependencies
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have always been a good boy when writing my classes, prefixing all member
I'm trying to create a job roster for my Boy Scout Troop, and I'm
E.g A1:I A2:am A3:a A4:boy I want to merge them all to a single
Hoo-boy I've been struggling with this one all day. The redirect from the subdomains
While we were all twiddling our thumbs, a 17-year-old Canadian boy has apparently found
Boy, this one is really weird. I expect the following code to print 1990,
Boy, I've got everything down-pat save the word referencing. The game crashes because of
This bad boy just does not want to change size to fill the dock
I've just started learning SSL and boy is it confusing Q1 - How long
I have the string: i am a bad boy. I want to convert that

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.