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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T02:16:00+00:00 2026-06-13T02:16:00+00:00

How to use a php extension like mcrypt? My first thought was to find

  • 0

How to use a php extension like mcrypt? My first thought was to find mcrypt.php and simply include it (context.Include(“mcrypt.php”, false);), but of course that doesn’t exist since it is written in C.
I was reading over Writing compiled PHP extensions in PHP post from the blog but that seems to be about creating your own extension for use in .net. But maybe Im wrong considering this statement: “Implement Phalanger extension in PHP langage. When you take your PHP library and compile it using Phalanger, the result is DLL working as any other extension”
But even still phpc (phalanger php compiler) is not going to compile c code as far as I know though I haven’t tried.

these are the calls my php class is trying to make:
mcrypt_module_open
mcrypt_enc_get_key_size
mcrypt_enc_get_block_size

  • 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-13T02:16:01+00:00Added an answer on June 13, 2026 at 2:16 am

    Jakub Míšek’s answer is definitely right and if this post helps you please vote him up as well. However I wanted to simplify what he said as his advice still took me some time to understand what he was saying. Also please Jakub if you get a chance to read this correct me if Im wrong about anything.

    First thing that got me about his answer was this file

    php_mcrypt.mng

    mng what is that????
    But after digging through their [Phalanger] svn and the files located in

    C:\Program Files\Phalanger 3.0\Wrappers

    I found the mcrypt file. Also with some help from the php chat room I got a clue as to what the mng was, Managed Code.

    So after adding the file as a reference as well as editing the web.config file to include it (as Jakub shows)

      <phpNet>
        <classLibrary>
          <add assembly="php_mcrypt.mng, Version=3.0.0.0, Culture=neutral, PublicKeyToken=4ef6ed87c53048a3" section="mcrypt" />
        </classLibrary>
        <scriptLibrary/>
      </phpNet>
    

    These lines must be feeding into Phalanger to load this extension when compiling (I think/know).

    After that everything seems to compile and run fine! Thanks Jakub

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

Sidebar

Related Questions

Does PHP have an extension that permits to use a tar.gz like a folder?
I'm trying to install the PECL extension pecl_http so that I can use PHP's
I have created a PHP Extension in C but i would like to provide
I read it's possible to use C/C++ code in PHP by writing an extension.
I use PHP Gettext extension for localizing a Web app. When you do: bindtextdomain(example,
I would like to use my function, for example DebugR() , but I don't
I am trying to write a PHP extension that executes some operations for specific
I know that you can use a php file as an external javascript file
I use php to build web applications, but i want my web pages without
i'm writing a php extension for my c++ library which is defined something like

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.