473,654 Members | 3,076 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Eclipse for building PHP sites?

Hello,

I recently installed eclipse with the php plugin.

My question is: can eclipse be used in a medium size site where php file
include others?

Or when you use an MVC approach. To be more specific.

I started coding a site with implementing my own simple mvc approach
(not a framework). I have separated the files physically into folders:
views/ and controllers/. The file views/albumview.php includes a file
include('top.ph p'). The file views/albumview.php is included from a file
index.php in the root directory and top.php is also located at the root
directory.

So when the application is running index.php includes
views/albumview.php which includes top.php. That's ok. But eclipse shows
a warning when views/albumview.php includes top.php because it searches
for top.php in views/ folder. So I have a bunch of warnings like this.
Sorry If I messed you up with my poor english grammar!

Generally speaking how should a site like this be developed? I use
bluefish for 3-4 years now but I 'm getting tired of doing silly and
simple mistakes[1] which the only way to find is to alt-tab to firefox
reload, see the error, alt-tab to the editor and fix it.

Thanks a lot
--------------------------------------
[1] like forgeting to close a ), using variables without $, etc
Jun 2 '08 #1
1 1395
Harris Kosmidhs wrote:
Hello,

I recently installed eclipse with the php plugin.

My question is: can eclipse be used in a medium size site where php file
include others?

Or when you use an MVC approach. To be more specific.

I started coding a site with implementing my own simple mvc approach
(not a framework). I have separated the files physically into folders:
views/ and controllers/. The file views/albumview.php includes a file
include('top.ph p'). The file views/albumview.php is included from a file
index.php in the root directory and top.php is also located at the root
directory.

So when the application is running index.php includes
views/albumview.php which includes top.php. That's ok. But eclipse shows
a warning when views/albumview.php includes top.php because it searches
for top.php in views/ folder. So I have a bunch of warnings like this.
Sorry If I messed you up with my poor english grammar!

Generally speaking how should a site like this be developed? I use
bluefish for 3-4 years now but I 'm getting tired of doing silly and
simple mistakes[1] which the only way to find is to alt-tab to firefox
reload, see the error, alt-tab to the editor and fix it.
Eclipse is great tool, I use it everyday for all sorts of projects.
Static code analyze is not yet at it's top possible quality in the PDT,
so you might ignore some warnings. It's there just to give you a hint,
that something might need your attention.

In bigger projects, as the number of files grow, including them usually
causes some problems. Popular solution to it is to use __autoload function.
http://www.php.net/manual/pl/language.oop5.autoload.php

You cant really get rid of mistakes. All what you can do is to detect
them early. Testing is my answer to this problem. Check PHPUnit.de.

For Eclipse relatd questions, i recomend using eclipse.tools.p dt
newsgroup at news.eclipse.or g (you need to register, but it's free)

Also, PDT has good Xdebug support, so check that too. It's support is in
that same news group.
best regards
Piotr N
Jun 2 '08 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
7594
by: Bennett Haselton | last post by:
I'm looking for a PHP tutorial that specializes in how to build sites that are based around user logins. i.e. the user logs in on the front page, and are taken to a main login page where fields on the page are populated with values from some server-side database. Ideally, there would be a server-side "user" database table, with fields such as "age", so that you could insert a short tag in the PHP source like: Your age is: <?php ?> ...
2
3052
by: Jim Hargrave | last post by:
Eclipse provides a very nice application framework which supports plug-ins. It's easy to dynamically add new functionality, menu items, property editors, options etc.. using a combination of XML and Java code. Is there a similar framework for Python? If not any hints on how such a framework would be implemented? I'm building a client side tool using Python/wxPython for our translators and would like to have a pluggable architecture...
29
3645
by: seberino | last post by:
I'm trying to move beyond Emacs/Vim/Kate and was wondering if Eclipse is better and if it is the *best* IDE for Python. Should I leave Emacs and do Python coding in Eclipse? Chris
3
3168
hirak1984
by: hirak1984 | last post by:
I have the following error while running a jar file built using eclipse==> " Failed to load Main-Class manifest attribute from C:\Documents and Settings\195156\Workspace\tool1.jar " tool1.jar is the name i have given to the jar file. The class that contains the "main(String a)" function is "test2.class" and i have 4 more classes.I have created a META-INF folder under the project root directory,and created a file named"MANIFEST.MF"....
0
1995
by: Husey | last post by:
Hi, I am trying to create a very simple EJB project which requires me to create a new jboss configuration in Eclipse. I keep getting the error message "An error has occurred. See error log for more details". Same for all versions of JBoss. I couldn't find what causes the error. Any help would be much appreciated. My installation is: JDK 1.5.0 update 11 Jboss 4.0.4GA Eclipse 3.2.2
4
2216
by: ramadeviirrigireddy | last post by:
Hi Can anyone tell me the exact site to install eclipse,tomcat and plug-ins(including versions) need for web application development . i saw so many sites and i got confused so asking you people the whole details.I have tried with eclipse 3.3.0 tomcat 4.0 but i have'nt found the correct plug-in for those things.(i got errors while starting tomcat.)is it compulsory to download the plug-ins which will suit for the version or any plug-in will...
16
10757
by: Ananthu | last post by:
Hi I dont know how to connect mysql with ECLIPSE in RCP application. Please send me the sample code of connecting mysql sever with ECLIPSE in RCP application. Coding Part: RCP Application Codes: Class ApplicationActionBarAdvisor:
3
6758
by: ravit | last post by:
Hello All, I am trying to execute an application that is developed using eclipse libraries. Jface, SWT , etc. While I execute the application , i have received an exception which I am unable to trace it. TextViewer.setSelection(100,true); is the statement whre it araised. TextViewer is org.eclipse.jface.text.SourceViewer object.
4
1124
hsn
by: hsn | last post by:
hello. please press on this link to see the screen shot of the problem http://sites.google.com/site/onlinehsn/pic2 with eclipse sometimes for a certain code which uses the jess expert system, most of the time it works perfectly but sometimes this message comes and i have to close eclipse and run it again so the code could run. this message always comes after atleast one time of running the code. can someone plz help me with explaining this...
0
8375
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8593
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7306
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5622
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4149
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4294
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2714
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1916
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1593
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.