In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-18 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)06/01 Report--
Comparison of the advantages of Zope and Apache+PHP+MySQL [@ more@] Zope can be compared with Apache+PHP+MySQL because it is a http server, a database, and a scripting language. Zope is now recommended because it has richer features, easier to build applications, and is several times more efficient than PHP. Today's server-side programming environments include IIS+ASP+ sqlserver, Apache+PHP+MySQL, and Zope. Zope is more professional for document publishing than it is.
I have used dw and frontpage to compile web pages, and I feel that frontpage's navigation system is better, and it can generate graphical titles, and a variety of professional templates. Dw's navigation system is almost impossible to use, but dw's web pages are more professional, and dw's templates have their own unique features. I thought about combining frontpage and dw, but it felt awkward. When there is more information on the website, the most urgent need is to put the data in the database, so it is easy to manage it uniformly. It is often strange that large websites often have a uniform appearance, rich navigation systems, and rich related links. There must be professional website management software and professional technical staff at the back of the website. So I often look for a website management system that can be used. I found Zope on the linuxfab.cx website and finally found what I wanted.
Whenever I recommend Zope to people, someone always says that I am good to use PHP, not to change it, or good to use ASP. ASP is similar to PHP in that scripting languages can be added to HTML. In comparison, I prefer ASP, which is based on vb, and because it has a separate scripting engine and can also support scripts such as Perl, Javascript, and so on. In this way, you can program in a language you are familiar with without learning a new language. And PHP is quite strange, originally very similar to Perl, why not just use Perl to achieve embedding in the page but also specifically invent a language to increase everyone's learning burden, although the language of PHP is a little clearer, but there is no fundamental difference, but the essence of Perl pattern matching is thrown away. Perl is also strange, why not introduce the same functionality as jsp? Therefore, I hate PHP psychologically, although its close integration with the database and the ability to generate images are better. Although Zope is excellent in website management, it is also a good programming environment. It supports the strong development momentum of Python and Perl,Python, and is good at compiling large programs. It is an object-oriented database with rich syntax, and can replace c and JAVA in many ways. It is much more efficient and attractive. I finished learning Python is not able to find the opportunity to use, Zope just gave me the opportunity to use Python, but also let me understand the power of Python. -> Zope the whole program is written in Python!
Zope is an object-oriented database, a document management database, a powerful http server, and a perfect development environment. From the essence and starting point, Zope is a document management database. It has a lot of document management functions.
Let's start with the advantages of Zope as a http server:
Although Zope is a database, all its documents are placed in the database rather than on the file system, but it has completed a file manager-like management interface and a ftp interface, can be used as a familiar file system, management habits are very familiar.
While Zope is an object-oriented database, object-oriented database is very different from general database. It is not based on table like relational database, but more tree-like like file system. From the point of view of the object, the field values of the record are the properties of the object. What it goes beyond the relational database is that it can adapt to a variety of data types, each data type is an object, there are not only a variety of properties, but also a variety of ways to manipulate specific data types. I often hear about object database, but I only come into contact with object database through Zope. (ingresql and userland products are also object databases)
The characteristic of Zope is to take files and folders as basic objects, and each file and folder can add attributes at will. At the same time, the files and folders under the folder are the attributes of the parent folder. By adding the form of script files, you can add methods to files and folders. For example, a file can add "author", "classification", "difficulty level" and other attributes, and a folder can also add the method of "displaying the contents of all files under this folder".
Zope also has its unique way to implement object-level inheritance. This method is "get". For example, the structure of the file system is / a _. If v is an attribute of b, you don't need to use a.b.v specifically to refer to it. In this way, the c file inherits a rich variable environment from all levels of folders. A typical example is that if the file standard_HTML_header is placed in the root directory, it can be referenced by files in any directory to show what each web page has in common. If you need your own unique web page effect in a directory, just put a unique standard_HTML_header in that directory. In this way, the files in this directory will get the header in this directory instead of the header in the root directory, thus realizing the personality of each column.
The form of acquisition can also be: c.mjournal m can be a method, that is, a script file, such as using m to make c have another form of representation. The m file can be placed under the b folder or under the a folder. The expression of c. M is valid. In this way, I put m in the root directory, and all the files on the site have a method m.
You can also support this fetch with url, such as calling method m with http://my.com/a/b/c/m. Similarly, the variable environment of m is / a/b/c.
Summary: as a http server, Zope can make the files and folders in the server have rich additional information such as properties and methods. It is convenient for the operation of file search, management and performance. At the same time, it also provides convenient file operation.
The current disadvantage of Zope is that external files cannot be used directly and are copied to the database through ftp. There is a remedy for this, but it is not the default of Zope. It is hoped that Zope will be able to manipulate external files and files of other websites in the same way as its own objects.
Advantages of Zope as a database:
From the above discussion, we have a general impression of the performance of Zope as a database. Compared with other databases, Zope is an object-oriented document database.
Unlike MySQL,Zope, which has a visual management interface, all the management of Zope is done through web. The advantage of web interface is that it is cross-platform, can be operated remotely and is convenient for interface customization. The management interface of Zope is similar to that of a file manager. When you click on a file, you can use the same web interface to edit and add attributes, security management and so on. Zope script debugging is also done with web.
As a database, Zope has powerful user rights management function, its user and rights management is very powerful, it can add users under a certain folder, but also has its own security rights management for specific objects.
The main data in the database of the website is documents. As a document database, Zope has powerful document management function, version management, history record function and full-text retrieval function. At the same time, the document editing environment and management environment are integrated, and the management of documents is as convenient as in the file manager. These are what the general database does not have.
If there are tens of thousands of records in the database, Zope will be less efficient than traditional databases, but Zope has a large number of adapters to link to various databases. To achieve pure table operations and a large number of record operations.
Advantages of Zope as a programming and customized environment:
Zope has dtml (dynamic template markup) language to embed in HTML to realize the dynamic web page. Dynamic content can be inserted simply by using the local form. Because you can easily add properties and methods and the "get" function, the document has a very rich variable environment. It can provide more powerful functionality than the average client. There is also a form to easily obtain the contents of multiple files. You can also embed Python expressions in dtml. In this way, it has powerful dynamic web page function without programming, and it is easy to realize navigation function and so on. These functions are much easier to implement than languages such as PHP.
If you want to add complex functions, you can use the script module to implement functions and complex operations, and then call the script module in dtml, thus achieving the separation of logic and presentation. Python, Perl and sql are allowed to be used as scripting languages in Zope, and all kinds of scripts can be called each other, thus realizing the mixed programming of multiple languages and realizing the purpose of mixed programming that .NET wants to achieve. Zope provides a unified Zope API for scripting languages. In this way (with dtml as the media) Perl can also achieve the effect of embedding HTML in unix. Blessed are Perl enthusiasts. Here you can manipulate the database directly with sql, eliminating the hassle of embedding sql in other languages.
Zope puts forward the concept of zclass, bundling a series of properties and methods for specific purpose data in a product, and even editing and viewing interfaces, specific permissions, help, and so on. For example, taking a task as a zclass, the task has attributes such as the issuer of the task, the executor of the task, the start time, the completion time and the content of the task, and there can also be a method for the establishment and completion of the task. In this way, a letter is sent to the executor when the build method is called, and to the sender when the completion method is called. At the same time, we should have the web editing interface of the task, issue the task and modify the permission definition of the task. When such a zclass is established, you can add a task instance to any folder. Zope first checks whether the user has permission to create a new task, and then calls up the task's editing interface to fill in various properties of the task, and there are also "create" and "finish" buttons to call the method. New features can be easily added to Zope through zclass. This concept of product is a function that languages such as PHP do not have, and a complex function can be accomplished clearly through product,Zope.
At the same time, in the implementation of product, we can not only call Zope API, but also directly call various modules of Zope itself to achieve more complex functions. Because Zope is open source and implemented by Python, when you encounter difficulties in programming, you can refer to the source code of Zope at any time, easily call Zope modules and functions, and even modify Zope code, which are not available in other programming environments.
The user management, version management and other functions of Zope are also realized through product, so Zope has a standard and open development environment.
I just read an article recently. It uses the relationship between dos and windows to compare Apache and Zope. In Apache, you have to do everything yourself. If you don't do it yourself, you have to assemble a lot of different programs to complete your tasks, and everyone's choices are different. As a result, there is no common language with each other, just like writing dos programs. First of all, you should go everywhere to catch some graphics programs, printing programs, sound programs, installation programs, and so on, to gather together, so that it is easy to go wrong. In Zope, there are many unified API, when you complete a product, user management, rights management, management interface, editing interface, etc., these are included in Zope, there is API available, you do not have to be busy. For example, like zwiki, you hardly need it. Zope itself is a collaborative product with its own user management and version management, so you don't have to waste time starting from scratch. There is a good saying in the article: "the worst unified programming interface is better than none." To cmf,Zope also provides a very rich API.
Finally, if you are not satisfied with Zope, you can also use cmf (content management framework, the secondary development platform of Zope) to build, manage websites, and develop new features. Cmf has made a lot of extensions to Zope user management, document management and product to achieve more high-end functions. About the functions of cmf, you need to write another article to describe.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.