Call a function in Shared Library on Linux

I created a shared library written in C/C++. How do I a call a function in the shared library from PHP ?

Functions in shared library:
void SetCurrentPos(int pos)

int GetCurrentPos()
     return m_Pos;

Could anyone show me a simple example of how I could call the above function in PHP ? Thanks.
Who is Participating?

[Webinar] Streamline your web hosting managementRegister Today

babuno5Connect With a Mentor Commented:
here is a sample tutorial from ZEND about Writing Extensions for PHP
another link that can help
All Courses

From novice to tech pro — start learning today.